fail to deploy cloudBeaver

cloudbeaver is a web sql query builder. It has docker releases, and works fine outside shiny proxy. see Run Docker Container · dbeaver/cloudbeaver Wiki · GitHub

I did try to deploy with the bellow spec without success:

    - id: dbeaver
      container-image: dbeaver/cloudbeaver:24.1.5
      port: 8978
      container-cmd: ["/opt/cloudbeaver/run-server.sh"]

The current behavior is:

  • the cloudbeaver container starts up and running fine (I did connect inside and ps shows the cloudbeaver java process is running fine)
  • there is no error in the shiny proxy logs
  • the icon of the application shows up for few seconds, but then the bellow error then comes up
Something went wrong.

REFRESH
Resource Error: GraphQL Error (Code: 404): {"response":{"status":404,"data":"not found","headers":{"map":{"cache-control":"no-cache, no-store, max-age=0, must-revalidate","content-type":"application/json","date":"Tue, 20 Aug 2024 19:39:20 GMT","expires":"0","pragma":"no-cache","server":"nginx/1.18.0","strict-transport-security":"max-age=31536000 ; includeSubDomains","vary":"Origin, Access-Control-Request-Method, Access-Control-Request-Headers","x-content-type-options":"nosniff","x-xss-protection":"0"}}},"request":{"query":"\n    query serverConfig {\n  serverConfig {\n    ...ServerConfig\n  }\n}\n    \n    fragment ServerConfig on ServerConfig {\n  name\n  version\n  workspaceId\n  serverURL\n  rootURI\n  containerId\n  defaultAuthRole\n  defaultUserTeam\n  productConfiguration\n  supportsCustomConnections\n  sessionExpireTime\n  anonymousAccessEnabled\n  adminCredentialsSaveEnabled\n  publicCredentialsSaveEnabled\n  resourceManagerEnabled\n  configurationMode\n  developmentMode\n  redirectOnFederatedAuth\n  distributed\n  enabledFeatures\n  disabledBetaFeatures\n  enabledAuthProviders\n  supportedLanguages {\n    isoCode\n    displayName\n    nativeName\n  }\n  disabledDrivers\n}\n    "}}
Resource Error: GraphQL Error (Code: 404): {"response":{"status":404,"data":"not found","headers":{"map":{"cache-control":"no-cache, no-store, max-age=0, must-revalidate
","content-type":"application/json","date":"Tue, 20 Aug 2024 19:39:20 GMT","expires":"0","pragma":"no-cache","server":"nginx/1.18.0","strict-transport-security":"max-age=31536000 ; includeSubDomains","vary":"Origin, Access-Control-Request-Method, Access-Control-Request-Headers","x-content-type-options":"nosniff","x-xss-protection":"0"}}},"request":{"query":"\n    query serverConfig {\n  serverConfig {\n    ...ServerConfig\n  }\n}\n    \n    fragment ServerConfig on ServerConfig {\n  name\n  version\n  workspaceId\n  serverURL\n  rootURI\n  containerId\n  defaultAuthRole\n  defaultUserTeam\n  productConfiguration\n  supportsCustomConnections\n  sessionExpireTime\n  anonymousAccessEnabled\n  adminCredentialsSaveEnabled\n  publicCredentialsSaveEnabled\n  resourceManagerEnabled\n  configurationMode\n  developmentMode\n  redirectOnFederatedAuth\n  distributed\n  enabledFeatures\n  disabledBetaFeatures\n  enabledAuthProviders\n  supportedLanguages {\n    isoCode\n    displayName\n    nativeName\n  }\n  disabledDrivers\n}\n    "}}
    at ServerConfigResource.markError (https://my-domain.com/app_proxy/affb8fe6-b331-480c-a2d2-18ee14976689/js/packages-908a78f7e16b1551951a.js:2:111669)
    at executeAction (https://my-domain.com/app_proxy/affb8fe6-b331-480c-a2d2-18ee14976689/js/vendor-06d28e940c924a11f03c.js:2:94191)
    at ServerConfigResource.markError (https://my-domain.com/app_proxy/affb8fe6-b331-480c-a2d2-18ee14976689/js/vendor-06d28e940c924a11f03c.js:2:93590)
    at Object.error (https://my-domain.com/app_proxy/affb8fe6-b331-480c-a2d2-18ee14976689/js/packages-908a78f7e16b1551951a.js:2:115548)
    at https://my-domain.com/app_proxy/affb8fe6-b331-480c-a2d2-18ee14976689/js/packages-908a78f7e16b1551951a.js:2:100232
    at Task.task (https://my-domain.com/app_proxy/affb8fe6-b331-480c-a2d2-18ee14976689/js/packages-908a78f7e16b1551951a.js:2:98717)

I fixed by adding this in the specs:

      target-path: "#{proxy.getRuntimeValue('SHINYPROXY_PUBLIC_PATH').replaceFirst('/$','')}"
      container-env:
        WWW_ROOT_PATH: "#{proxy.getRuntimeValue('SHINYPROXY_PUBLIC_PATH').replaceFirst('/$','')}"

Also add to specify the rootUri in the cloudbeaver.conf file:

{   "server": {
# ...
   "rootURI": "${WWW_ROOT_PATH}",
# ...

now the app resolves the dependencies.

2 Likes