Blazer quickstart

This quickstart guide will help you get Blazer up and running with Container Apps on Crunchy Bridge. We recommend you start with the Container Apps Quickstart to get a general understanding of Container Apps.

Additional documentation for the Blazer Docker image can be found on the Blazer Docker GitHub page.

About Blazer

From the Blazer project:

Explore your data with SQL. Easily create charts and dashboards, and share them with your team.

Blazer with container apps quickstart

First ensure you have Container Apps enabled with CREATE EXTENSION pgpodman;.

Next, find your cluster's database URL to include as the DATABASE_URL parameter when you run the container. You can find the URL in the Connection section of the cluster dashboard (choose the application role), or by running cb uri --role application <cluster name> on the command line.

Initialize the tables used by Blazer using your own value for DATABASE_URL:

SELECT run_container('-dt -e DATABASE_URL="your-database-URL" --privileged rails db:migrate');

The initialization will run and its container will exit.

To start your Blazer app, run the following using your own value for DATABASE_URL:

SELECT run_container('-dt -p 5433:8080/tcp -e DATABASE_URL="your-database-URL" --privileged');

Now you can visit your running Blazer app at your-host-URL:5433. You can find your Host URL in the Overview section of your cluster dashboard, or by running cb info <cluster name>.

Configuring simple authentication for Blazer

By default, the above setup will create a public app that anyone who knows the URL can access. It is recommended that you set up authentication. You can set up basic authentication by setting the BLAZER_USERNAME and BLAZER_PASSWORD values when you initiate the Container App:

SELECT run_container('-dt -p 5433:8080/tcp -e DATABASE_URL="your-database-URL" -e BLAZER_USERNAME="desired-username" -e BLAZER_PASSWORD="desired-password" --privileged');