Create a Postgres Connection

White Label Data allows you to use Postgres as a data warehouse and to map query results to native White Label Data visualizations. In order to use Postgres, you must first set up a connection in White Label Data.

Example appconfig.json:

 "connections" : [
            "type" : "postgres",
            "host" : "",
            "username" : "postgres",
            "port" : "5432",
            "database" : "MY_WAREHOUSE",
            "env_var" : "POSGRES_PASSWORD"
Option Example Description
host "" DNS name or IP address of the PostgreSQL database.
username "postgres" The username to connect to the PostgreSQL server with.
port "5432" Port to connect to PostgreSQL database.
database "postgres" Name of the database instance.
ssl {"keyfile": "…​",
"certfile": "…​",
"ca_certs": "…​""}
Optional. A dictionary of SSL configuration parameters to enable encryption over the TCP/IP connection. Omitting this parameters means that SSL is disabled. The parameters have the same meaning as those in the ssl.wrap_socket function.
env_var "POSTGRES_PASSWORD" Name of environment variable that will hold the Postgres password.

Note: You must also add this environment variable to your environment settings for your instance. See “Adding connection environment variables to your local development environment” here.