53 lines
1.0 KiB
YAML
53 lines
1.0 KiB
YAML
version: '3'
|
|
|
|
services:
|
|
|
|
db:
|
|
image: mysql:latest
|
|
container_name: MySQL
|
|
restart: always
|
|
|
|
environment:
|
|
# MYSQL_DATABASE: "service_manage"
|
|
MYSQL_USER: "tongji"
|
|
MYSQL_PASSWORD: "lldlcj123"
|
|
MYSQL_ROOT_PASSWORD: "lldlcj123"
|
|
TZ: "UTC" # 容器日志大小配置
|
|
command: --character-set-server=utf8mb4 --collation-server=utf8mb4_general_ci
|
|
logging:
|
|
driver: 'json-file'
|
|
options:
|
|
max-size: '5g'
|
|
ports:
|
|
- 6306:3306
|
|
volumes:
|
|
- db:/var/lib/mysql
|
|
network_mode: "bridge"
|
|
|
|
phpmyadmin:
|
|
image: phpmyadmin:latest
|
|
container_name: phpmyadmin_1
|
|
network_mode: "bridge"
|
|
environment:
|
|
# - PMA_USER=root
|
|
# - PMA_PASSWORD=lldlcj123
|
|
# - MYSQL_ROOT_PASSWORD=lldlcj123
|
|
- PMA_HOST=192.168.222.5
|
|
- PMA_PORT=6306
|
|
# 任意服务器一起使用
|
|
# - PMA_ARBITRARY=1
|
|
- TZ=UTC
|
|
restart: always
|
|
ports:
|
|
- 8090:80
|
|
volumes:
|
|
- sessions:/sessions
|
|
# depends_on:
|
|
# links:
|
|
# - db
|
|
|
|
volumes:
|
|
db:
|
|
cfg:
|
|
sessions:
|