This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.
# 本地 MySQL(可选):与本项目 .env 中 DB_PORT=3307、库名/账号默认对齐
# 启动:docker compose up -d
# 停止:docker compose down
services:
mysql:
image: mysql:8.0
container_name: slake-school-mysql
restart: unless-stopped
environment:
MYSQL_DATABASE: slake_school
MYSQL_USER: slake
MYSQL_PASSWORD: slake_local
MYSQL_ROOT_PASSWORD: root_local
ports:
- "3307:3306"
volumes:
- slake_school_mysql:/var/lib/mysql
command: >
--default-authentication-plugin=mysql_native_password
--character-set-server=utf8mb4
--collation-server=utf8mb4_unicode_ci
slake_school_mysql: