This Docker Compose configuration allows you to set up Metabase along with a PostgreSQL database.
This configuration is designed for Metabase version 3.9.
/dev/urandom:/dev/random:ro
3000:3000
MB_DB_TYPE
: postgresMB_DB_DBNAME
: metabaseMB_DB_PORT
: 5432MB_DB_USER_FILE
: /run/secrets/db_userMB_DB_PASS_FILE
: /run/secrets/db_passwordMB_DB_HOST
: postgrescurl --fail -I http://localhost:3000/api/health || exit 1
POSTGRES_USER_FILE
: /run/secrets/db_userPOSTGRES_DB
: metabasePOSTGRES_PASSWORD_FILE
: /run/secrets/db_passworddb_password.txt
and db_user.txt
files with your PostgreSQL password and username, respectively.Run the following command to start Metabase and PostgreSQL:
```bash docker-compose up -d