Articles in this section
Category / Section

Deploying Bold BI on Docker with a Self-Signed Certificate for Windows Localhost

Published:

This section provides detailed instructions on how to activate SSL for a Bold BI instance running inside a Docker container on your local Windows machine using a self-signed certificate. Follow these steps:

Step 1: Install OpenSSL for Windows

Install OpenSSL on Windows using the following link: OpenSSL Installation for Windows

image.png

Step 2: Generate a New OpenSSL Configuration File

Create a new file named openssl.cnf (or openssl-san.cnf) with the provided content that includes the SAN (Subject Alternative Name) extension.

[ req ]
default_bits        = 2048
default_md          = sha256
default_keyfile     = localhost.key
distinguished_name  = req_distinguished_name
req_extensions      = req_ext
x509_extensions     = v3_req # The extensions to add to the self-signed cert

[ req_distinguished_name ]
countryName                 = Country Name (2 letter code)
countryName_default         = US
stateOrProvinceName         = State or Province Name (full name)
stateOrProvinceName_default = State
localityName                = Locality Name (eg, city)
localityName_default        = City
organizationName            = Organization Name (eg, company)
organizationName_default    = My Company
commonName                  = Common Name (e.g. server FQDN or YOUR name)
commonName_default          = localhost

[ req_ext ]
subjectAltName = @alt_names

[ v3_req ]
subjectAltName = @alt_names

[ alt_names ]
DNS.1   = localhost

Step 3: Generate the Certificate and Key

Use the custom configuration file to generate a new certificate and key:

  1. Generate a Private Key:
openssl genpkey -algorithm RSA -out localhost.key

image.png

  1. Generate the Certificate:
openssl req -x509 -new -nodes -key localhost.key -sha256 -days 365 -out localhost.crt -config openssl.cnf

image.png

Step 4: Bold BI Installation with the Generated Certificate

Deploy Bold BI on Docker Using the generated certificate.key and certificate.crt Files.

  1. To install Bold BI within a Docker container, you can utilize either a Docker or a docker-compose file. For guidance and instructions, please refer to the following link.
  2. Once the Bold BI is deployed, proceed to set up SSL for the application by following the instructions at this link.
  3. After configuring SSL, accessing the site might result in an error like the one shown below. To resolve this, you’ll need to import the certificate into the Windows Trusted Root store.
    image.png

Step 5: Import the Certificate to Windows Trusted Root

Importing the certificate to Windows Trusted Root allows Windows and browsers to trust the self-signed certificate, preventing security warnings and ensuring secure communication for users accessing the site.

  1. Import the certificate into Windows that you obtained in step 3:
    • Press Win + R, type mmc, and press Enter.
      image.png
    • In the MMC console, go to File > Add/Remove Snap-in....
      image.png
    • Select Certificates and click Add.
      image.png
    • Choose Computer account, then click Next.
      image.png
    • Select Local computer and click Finish.
      image.png
    • Then click OK in the Add/Remove Snap-ins window.
    • In the MMC console, expand Certificates > Trusted Root Certification Authorities.
      image.png
    • Right-click on Certificates, then select All Tasks > Import.
      image.png
    • Follow the wizard to import your localhost.crt file. Ensure it is placed in the Trusted Root Certification Authorities store.
      image.png
    • Finish the wizard, and you should see your localhost certificate listed under Trusted Root Certification Authorities > Certificates.
      image.png

Step 6: Verifying the Setup in Browser

  1. Restart your browser: Close and reopen browser to ensure it picks up the newly trusted certificate.
  2. Clear Cache: If you still encounter any warning issue, clear the browser cache.
  3. Access the HTTPS URL: Navigate to https://localhost or your custom local domain (if you set one up).
  4. Browser should no longer display a security warning, indicating it trusts the certificate.
    image.png

Additional Resources

  1. How to Install and Use SSL Certificate Manually in Windows IIS for Bold BI Site
  2. How to Install SSL Certificate on Nginx Server in Linux for Bold BI?
  3. How to renew an SSL certificate in an EKS cluster using your own certificates?
Was this article useful?
Like
Dislike
Help us improve this page
Please provide feedback or comments
PS
Written by Priya Sunil Kumar
Updated
Comments (0)
Please  to leave a comment
Access denied
Access denied