[GH-ISSUE #3437] Exposing cloudbeaver via Apache proxy #1259

Closed
opened 2026-03-07 21:01:44 +03:00 by kerem · 8 comments
Owner

Originally created by @avhz on GitHub (May 12, 2025).
Original GitHub issue: https://github.com/dbeaver/cloudbeaver/issues/3437

Originally assigned to: @yagudin10 on GitHub.

Hi :)

Having issues with exposing CloudBeaver via Apache.

I have:

RedirectMatch permanent ^/dbeaver$ /dbeaver/

RewriteRule      /dbeaver/(.*) ws://localhost:1234/$1  [P,L]
RewriteRule      /dbeaver/(.*) http://localhost:1234/$1 [P,L]

ProxyPass        /dbeaver/     http://localhost:1234/
ProxyPassReverse /dbeaver/     http://localhost:1234/

Port 1234 is forwarded to the cloudbeaver port 8978 in the docker container.

I also set:

CB_SERVER_URL: https://example.com/dbeaver/
CLOUDBEAVER_ROOT_URI: /dbeaver/

But I get a 404 Not Found error.

Anything I've messed up ?

Originally created by @avhz on GitHub (May 12, 2025). Original GitHub issue: https://github.com/dbeaver/cloudbeaver/issues/3437 Originally assigned to: @yagudin10 on GitHub. Hi :) Having issues with exposing CloudBeaver via Apache. I have: ``` RedirectMatch permanent ^/dbeaver$ /dbeaver/ RewriteRule /dbeaver/(.*) ws://localhost:1234/$1 [P,L] RewriteRule /dbeaver/(.*) http://localhost:1234/$1 [P,L] ProxyPass /dbeaver/ http://localhost:1234/ ProxyPassReverse /dbeaver/ http://localhost:1234/ ``` Port `1234` is forwarded to the cloudbeaver port `8978` in the docker container. I also set: ``` CB_SERVER_URL: https://example.com/dbeaver/ CLOUDBEAVER_ROOT_URI: /dbeaver/ ``` But I get a 404 Not Found error. Anything I've messed up ?
kerem 2026-03-07 21:01:44 +03:00
Author
Owner

@EvgeniaBzzz commented on GitHub (May 12, 2025):

Hi @avhz
Could you please provide us with server log?
And what CB version do you use?

<!-- gh-comment-id:2872292221 --> @EvgeniaBzzz commented on GitHub (May 12, 2025): Hi @avhz Could you please provide us with server log? And what CB version do you use?
Author
Owner

@avhz commented on GitHub (May 12, 2025):

Hi @EvgeniaBzzz :)

I'm very sorry, it's a bit annoying but I don't have access to the server logs, it's managed elsewhere. I can just see the config.

My compose is:

services:
  dbeaver:
    image: dbeaver/cloudbeaver:latest ## v25 currently I believe
    container_name: dbeaver
    restart: unless-stopped
    ports:
      - 1234:8978
    volumes:
      - ./dbeaver/logs:/opt/cloudbeaver/logs
      - ./dbeaver/workspace:/opt/cloudbeaver/workspace
    environment:
      CB_SERVER_URL: https://example.com/dbeaver/
      CLOUDBEAVER_ROOT_URI: /dbeaver/
<!-- gh-comment-id:2872328544 --> @avhz commented on GitHub (May 12, 2025): Hi @EvgeniaBzzz :) I'm very sorry, it's a bit annoying but I don't have access to the server logs, it's managed elsewhere. I can just see the config. My compose is: ```yaml services: dbeaver: image: dbeaver/cloudbeaver:latest ## v25 currently I believe container_name: dbeaver restart: unless-stopped ports: - 1234:8978 volumes: - ./dbeaver/logs:/opt/cloudbeaver/logs - ./dbeaver/workspace:/opt/cloudbeaver/workspace environment: CB_SERVER_URL: https://example.com/dbeaver/ CLOUDBEAVER_ROOT_URI: /dbeaver/ ```
Author
Owner

@EvgeniaBzzz commented on GitHub (May 12, 2025):

What URL are you getting the 404 on?

<!-- gh-comment-id:2872372132 --> @EvgeniaBzzz commented on GitHub (May 12, 2025): What URL are you getting the 404 on?
Author
Owner

@avhz commented on GitHub (May 12, 2025):

https://example.com/dbeaver/

Note: If I drop the two environment variables above, it resolves and I see the cloudbeaver loading screen for a moment, but then it redirects to https://example.com/#/, and I get "Resource Error".

<!-- gh-comment-id:2872380058 --> @avhz commented on GitHub (May 12, 2025): <https://example.com/dbeaver/> Note: If I drop the two environment variables above, it resolves and I see the cloudbeaver loading screen for a moment, but then it redirects to <https://example.com/#/>, and I get "Resource Error".
Author
Owner

@LonwoLonwo commented on GitHub (May 23, 2025):

Hello @avhz

Looks like this is specific of your Apache proxy and we cannot help you on this step :(

<!-- gh-comment-id:2904400970 --> @LonwoLonwo commented on GitHub (May 23, 2025): Hello @avhz Looks like this is specific of your Apache proxy and we cannot help you on this step :(
Author
Owner

@avhz commented on GitHub (May 26, 2025):

Can you spot anything wrong with my Apache/Docker setup?
This setup works for all our other apps, and I'm stuck figuring out what the difference could be wrt CloudBeaver.

Or are there any docs related to this topic? I found the nginx info, but still can't find the issue.

<!-- gh-comment-id:2909344199 --> @avhz commented on GitHub (May 26, 2025): Can you spot anything wrong with my Apache/Docker setup? This setup works for all our other apps, and I'm stuck figuring out what the difference could be wrt CloudBeaver. Or are there any docs related to this topic? I found the nginx info, but still can't find the issue.
Author
Owner

@yagudin10 commented on GitHub (May 28, 2025):

Hi, @avhz !
Could you try to update your Apache configuration to

ProxyPass        /dbeaver/     ws://localhost:1234/dbeaver/
ProxyPassReverse /dbeaver/     ws://localhost:1234/dbeaver/

ProxyPass        /dbeaver/     http://localhost:1234/dbeaver/
ProxyPassReverse /dbeaver/     http://localhost:1234/dbeaver/

and use the latest version of CloudBeaver?

<!-- gh-comment-id:2915904171 --> @yagudin10 commented on GitHub (May 28, 2025): Hi, @avhz ! Could you try to update your Apache configuration to ``` ProxyPass /dbeaver/ ws://localhost:1234/dbeaver/ ProxyPassReverse /dbeaver/ ws://localhost:1234/dbeaver/ ProxyPass /dbeaver/ http://localhost:1234/dbeaver/ ProxyPassReverse /dbeaver/ http://localhost:1234/dbeaver/ ``` and use the latest version of CloudBeaver?
Author
Owner

@avhz commented on GitHub (May 30, 2025):

Works now, thanks a lot :)

<!-- gh-comment-id:2921684069 --> @avhz commented on GitHub (May 30, 2025): Works now, thanks a lot :)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/cloudbeaver#1259
No description provided.