Created
November 10, 2021 07:44
-
-
Save jjromannet/9a5ee7e480801576b68af1ed5fd8e979 to your computer and use it in GitHub Desktop.
Dockercompose config tu run MySQL 5.7 that works
This file contains hidden or 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: "3.9" | |
services: | |
db: | |
image: mysql/mysql-server:5.7 | |
environment: | |
MYSQL_DATABASE: 'db' | |
MYSQL_ROOT_PASSWORD: 'secret-pw' | |
MYSQL_ROOT_HOST: '%' | |
ports: | |
- '3306:3306' | |
expose: | |
- '3306' | |
volumes: | |
- './.mysql-data/db:/var/lib/mysql' | |
- './initial.sql:/docker-entrypoint-initdb.d/initial.sql' | |
# for WebUI | |
adminer: | |
image: adminer:4.8.1 | |
ports: | |
- "8081:8080" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment