How to Deploy Bold BI Application on Docker Swarm
Bold BI supports both single-container and multi-container(docker-compose) deployment in Docker. Docker deployment allows you to build, test, and deploy applications quickly.
Docker compose:
- BoldBI in Single container image.
- BoldBI in Multi container image.
Single container Bold BI with docker-compose
- Create a docker-compose.yml file that starts your Bold BI instance with volume mounts for data persistence, or download this configuration file.
version: '3.5' services: boldbi: image: syncfusion/boldbi restart: always ports: - 8085:80 # environment: # - APP_URL=<app_base_url> networks: - boldbi volumes: - boldbi_data:/application/app_data pgdb: image: postgres restart: always environment: POSTGRES_PASSWORD: <Password> volumes: - db_data:/var/lib/postgresql/data/ networks: - boldbi networks: boldbi: volumes: boldbi_data: driver: local driver_opts: type: 'none' o: 'bind' device: '<host_path_boldbi_data>' db_data: driver: local driver_opts: type: 'none' o: 'bind' device: '<host_path_db_data>'
- Replace the <app_base_url> with your DNS or IP address, by which you want to access the application.
For example:
http://example.com
https://example.com
http://<public_ip_address>
Note:
- If you are using the IP address for the Base URL, make sure you are using the public IP of the machine instead of the internal IP or local IP address. Applications can communicate with each other using the public IP alone. Host machine IP will not be accessible inside the application container.
- Provide the HTTP or HTTPS scheme for APP_BASE_URL value.
- You can also change the Port number other than 8085.
- Allocate a directory in your host machine to store the shared folders for applications’ usage. Replace the directory path with <host_path_boldbi_data> in docker-compose.yml file.
For example:
Windows: device: 'D:/boldbi/boldbi_data' and device: 'D:/boldbi/db_data'
Linux: device: '/var/boldbi/boldbi_data' and device: '/var/boldbi/db_data'
Note: The docker volumes boldbi_data and db_data persists data of Bold BI and PostgreSQL respectively, click here to learn more.
- Run the following command from the project directory.
docker stack deploy --compose-file docker-compose.yml boldbi Note: The BoldBI site is not immediately available on port 8085 because the containers are still being initialized and may take a couple of minutes for the first load.
- Configure the Bold BI On-Premises application startup to use the application
Multi container Bold BI with docker-compose
- Download the configuration files here. This directory includes docker-compose YML file and configuration file for Nginx.
NOTE: You can use either a .yml or .yaml extension for this file. They both works well.
- Replace the <app_base_url> with your DNS or IP address, by which you want to access the application.
For example:
http://example.com
https://example.com
http://<public_ip_address>
- You can also change the Port number other than 8085.
- Provide the default.conf file, which you downloaded earlier in <default_conf_path> place.
For example, “./default.conf:/etc/nginx/conf.d/default.conf”
“D:/boldbi/docker/default.conf”:“/etc/nginx/conf.d/default.conf”
“/var/boldbi/docker/default.conf:/etc/nginx/conf.d/default.conf”reverse-proxy: container_name: nginx image: nginx restart: on-failure volumes: - "<default_conf_path>:/etc/nginx/conf.d/default.conf" # - "<ssl_cert_file_path>:/etc/ssl/domain.crt" # - "<ssl_key_file_path>:/etc/ssl/domain.key" ports: - "8080:80" # - "443:443" environment: - NGINX_PORT=80 networks: - boldbi depends_on: - id-web - id-api - id-ums - bi-web - bi-api - bi-jobs - bi-dataservice
- Allocate a directory in your host machine to store the shared folders for applications’ usage. Replace the directory path with the <host_path_boldservices_data> and <host_path_db_data> in docker-compose.yml
For example, Windows: device:'D:/boldbi/boldservices_data' and device: 'D:/boldbi/db_data'
Linux: device: '/var/boldbi/boldservices_data' and device: '/var/boldbi/db_data'
Note: The docker volumes boldservices_data and db_data persists data of Bold BI and PostgreSQL respectively, click here to learn more.
- Run the following command from the project directory.
docker stack deploy --compose-file docker-compose.yml boldbi
- BoldBI should be running in the <app_base_url>:8085 (as appropriate).
- Configure the Bold BI On-Premises application startup to use the application.
Related links