Dundas BI website docker container does not start

Hi all,

I am trying to dockerize Dundas BI following the official guide.

I am able to successfully set up the database container as well as the “setup” container using the following docker-compose manifest:

version: '3.7'
services:
  dundas-bi-db:
    container_name: dundas-bi-db
    image: postgres:13-alpine
    environment:
      - POSTGRES_USER=postgres
      - POSTGRES_PASSWORD=***
    volumes:
      - /path/to/my/local/folder:/var/lib/postgresql/data:rw

  dundas-bi-setup:
    container_name: dundas-bi-setup
    image: dundas/dundas-bi-setup:10
    environment:
      - A160BB4E4AE416297A0AAC7FACFCB751=HandleDatabase
      - DUNDAS_BI_DOCKER_EMAIL=***
      - DUNDAS_BI_DOCKER_KEY=***
      - DUNDAS_BI_ADMIN_PASSWORD=***
      - DUNDAS_BI_SETUP_ORCHESTRATOR_URL=
      - DUNDAS_BI_APP_STORAGE=Postgres
      - DUNDAS_BI_APP_DB_CONN_STRING=Server=dundas-bi-db;Port=5432;Database=dundas-bi;Username=postgres;Password=***
    links:
      - dundas-bi-db

Then I try to start the Dundas BI services using:

version: '3.7'
services:
  dundas-bi-website:
    container_name: dundas-bi-website
    image: dundas/dundas-bi-website:10
    environment:
      - DUNDAS_BI_INTERNAL_APPLICATION_URL=http://localhost:9010/
      - DUNDAS_BI_EXTERNAL_APPLICATION_URL=http://localhost:9010/
      - DUNDAS_BI_APP_STORAGE=Postgres
      - DUNDAS_BI_APP_DB_CONN_STRING=Server=dundas-bi-db;Port=5432;Database=dundas-bi;Username=postgres;Password=***
    expose:
      - '8080'

  dundas-bi-scheduler:
    container_name: dundas-bi-scheduler
    image: dundas/dundas-bi-scheduler:10
    environment:
      - DUNDAS_BI_APP_STORAGE=Postgres
      - DUNDAS_BI_APP_DB_CONN_STRING=Server=dundas-bi-db;Port=5432;Database=dundas-bi;Username=postgres;Password=***

  dundas-bi-authbridge:
    container_name: dundas-bi-authbridge
    image: dundas/dundas-bi-authbridge:10
    environment:
      - DUNDAS_BI_APP_STORAGE=Postgres
      - DUNDAS_BI_APP_DB_CONN_STRING=Server=dundas-bi-db;Port=5432;Database=dundas-bi;Username=postgres;Password=***

  dundas-bi-proxy:
    container_name: dundas-bi-proxy
    image: nginx:latest
    volumes:
      - ./nginx.conf:/etc/nginx/nginx.conf:ro
    depends_on:
      - dundas-bi-website
    ports:
      - '9010:80'

but the container dundas-bi-website fails with the error

The dbi.config file does not exist. The application will not be started.

Also the container dundas-bi-scheduler seems to raise some errors like

[Err] [Framework.Scheduler] 2900: The Scheduler service encountered an error connecting to the Dundas BI server at http://f68a9629b4e8/. Name or service not known (f68a9629b4e8:80) Ensure the value for the ‘Internal Application URL’ configuration setting is correct.

Although I am not sure if this error is actually a consequence of the previous one.

For completeness I attach the dundas-bi-proxy configuration as well:

user nginx;

events {
  worker_connections 1000;
}

http {
  server {
    listen 80;

    location /AuthBridge/ {
      proxy_pass http://dundas-bi-authbridge:8080/;

      proxy_http_version 1.1;

      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection keep-alive;
      proxy_set_header Host $http_host;

      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Forwarded-Proto $scheme;

      proxy_cache_bypass $http_upgrade;

      proxy_set_header X-Proxy-BaseUri /AuthBridge;

      proxy_buffer_size 128k;
      proxy_buffers 4 256k;
      proxy_busy_buffers_size 256k;

      proxy_connect_timeout 86400;
      proxy_send_timeout 86400;
      proxy_read_timeout 86400;
      send_timeout 86400;
      client_max_body_size 500M;
    }

    location / {
      proxy_pass http://dundas-bi-website:8080/;

      proxy_http_version 1.1;

      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection keep-alive;
      proxy_set_header Host $http_host;

      proxy_cache_bypass $http_upgrade;

      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Forwarded-Proto $scheme;

      proxy_connect_timeout 86400;
      proxy_send_timeout 86400;
      proxy_read_timeout 86400;
      send_timeout 86400;
      client_max_body_size 500M;
    }
  }
}

Have you ever faced a similar issue?

Many thanks in advance.
Gaetano

That strange URL being formed in the error message (the one the application is trying to spin up) is probably the name of container that created the application database. That property likely needs to to be updated in the Application Configuration setting. It can be done by setting an environment variable on startup (DUNDAS_BI_INTERNAL_APPLICATION_URL) or it can just be set in Dundas itself via the UI (log in as admin user, navigate to Admin > Setup > Config. That would at least fix the scheduler issue.

Hi Christian,

thanks a lot for the feedback. That was helpful, using the DUNDAS_BI_INTERNAL_APPLICATION_URL environment variable in the dundas-bi-scheduler container fixed indeed the second issue.

Now, on both dundas-bi-website and dundas-bi-scheduler I have the same error message:

The dbi.config file does not exist. The application will not be started .

Could this be a volume issue? I am guessing the dundas-bi-setup container generates some stuff for the services containers and maybe, among them, also a dbi.config which should be maybe shared via a docker volume. Does this make any sense to you?

I cannot find anything on the Dundas BI official guide with respect to that though.

Thanks again for your help.
Gaetano


UPDATE

I was finally able to successfully run the Dundas BI containers. Something was wrong in the way I was passing the connection strings to the authbridge and scheduler services.

Now I see that the DUNDAS_BI_INTERNAL_APPLICATION_URL environment variable has no effect if applied to the dundas-bi-scheduler container.

The error

[2022-08-19 08:32:55.605] [Err] [Framework.Scheduler] 2900: The Scheduler service encountered an error connecting to the Dundas BI server at http://localhost:9010/. Cannot assign requested address (localhost:9010) Ensure the value for the ‘Internal Application URL’ configuration setting is correct.

is now back in the scheduler log.


LAST UPDATE

I was able to fix the scheduler error as well using the dundas-bi-full docker image that combines the Dundas BI website scheduler and authbridge services into a single container. Here’s the docker-compose manifest I run in the end:

version: '3.7'

services:

  dundas-bi:
    container_name: dundas-bi
    image: dundas/dundas-bi-full:10
    environment:
      - DUNDAS_BI_EXTERNAL_APPLICATION_URL=http://localhost:9010/
      - DUNDAS_BI_APP_STORAGE=Postgres
      - DUNDAS_BI_APP_DB_CONN_STRING=Server=dundas-bi-db;Port=5432;Database=dundas-bi;Username=postgres;Password=***
    expose:
      - '8081'
      - '8082'

  dundas-bi-proxy:
    container_name: dundas-bi-proxy
    image: nginx:latest
    volumes:
      - ./nginx.conf:/etc/nginx/nginx.conf:ro
    depends_on:
      - dundas-bi
    ports:
      - '9010:80'

And the nginx proxy configuration as well:

user nginx;

events {
  worker_connections 1000;
}

http {
  server {
    listen 80;

    location /AuthBridge/ {
      proxy_pass http://dundas-bi:8082/;

      proxy_http_version 1.1;

      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection keep-alive;
      proxy_set_header Host $http_host;

      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Forwarded-Proto $scheme;

      proxy_cache_bypass $http_upgrade;

      proxy_set_header X-Proxy-BaseUri /AuthBridge;

      proxy_buffer_size 128k;
      proxy_buffers 4 256k;
      proxy_busy_buffers_size 256k;

      proxy_connect_timeout 86400;
      proxy_send_timeout 86400;
      proxy_read_timeout 86400;
      send_timeout 86400;
      client_max_body_size 500M;
    }

    location / {
      proxy_pass http://dundas-bi:8081/;

      proxy_http_version 1.1;

      proxy_set_header Upgrade $http_upgrade;
      proxy_set_header Connection keep-alive;
      proxy_set_header Host $http_host;

      proxy_cache_bypass $http_upgrade;

      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header X-Forwarded-Proto $scheme;

      proxy_connect_timeout 86400;
      proxy_send_timeout 86400;
      proxy_read_timeout 86400;
      send_timeout 86400;
      client_max_body_size 500M;
    }
  }
}
1 Like