Skip to content

Instantly share code, notes, and snippets.

@jjromannet
Created November 10, 2021 07:44
Dockercompose config tu run MySQL 5.7 that works
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