Last active
May 15, 2020 02:05
-
-
Save knshiro/489d1e87bbe8e65d32bb54822752b78e to your computer and use it in GitHub Desktop.
Docker compose for metabase and mysql (bonus phpyadmin)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "2.1" | |
services: | |
mysql-db: | |
image: mariadb:10.5 | |
volumes: | |
- ./mysql_data:/var/lib/mysql | |
restart: always | |
ports: | |
- 3307:3306 | |
environment: | |
MYSQL_ROOT_PASSWORD: dbmetabaserootpassword | |
MYSQL_DATABASE: metabase | |
MYSQL_USER: metabase | |
MYSQL_PASSWORD: metabasedatabasepassword | |
metabase-app: | |
image: metabase/metabase | |
restart: always | |
ports: | |
- 3001:3000 | |
volumes: | |
# declare your mount volume /host/dir:/container/dir | |
- ./metabase-data:/metabase-data | |
environment: | |
MB_DB_TYPE: mysql | |
MB_DB_DBNAME: metabase | |
MB_DB_PORT: 3306 | |
MB_DB_USER: metabase | |
MB_DB_PASS: metabasedatabasepassword | |
MB_DB_HOST: mysql-db | |
depends_on: | |
- mysql-db | |
links: | |
- mysql-db | |
phpmyadmin: | |
image: phpmyadmin/phpmyadmin:latest | |
container_name: metabase_pma | |
links: | |
- mysql-db | |
environment: | |
PMA_HOST: mysql-db | |
PMA_PORT: 3306 | |
PMA_ARBITRARY: 1 | |
restart: always | |
ports: | |
- 8185:80 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment