You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
1.2 KiB
41 lines
1.2 KiB
version: "3.8"
|
|
|
|
services:
|
|
mysql-101:
|
|
container_name: mysql-101
|
|
image: mysql:${MYSQL_VERSION}
|
|
restart: always
|
|
environment:
|
|
- TZ=Asia/Shanghai
|
|
- MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
|
|
ports:
|
|
- ${MYSQL_PORT1}:3306
|
|
volumes:
|
|
- /etc/localtime:/etc/localtime:ro
|
|
- ./data/mysql/mysql-101:/var/lib/mysql
|
|
- ./conf/mysql/mysql-101/my.cnf:/etc/mysql/conf.d/my.cnf
|
|
- ./conf/mysql/mysql-101/initdb.d:/docker-entrypoint-initdb.d
|
|
command: bash -c "chmod 644 /etc/mysql/conf.d/my.cnf && docker-entrypoint.sh --default-authentication-plugin=mysql_native_password"
|
|
healthcheck:
|
|
test: [ "CMD", "mysqladmin", "ping", "-h", "localhost" ]
|
|
interval: 10s
|
|
timeout: 10s
|
|
retries: 10
|
|
phpmyadmin:
|
|
image: phpmyadmin:${PHPMYADMIN_VERSION}
|
|
restart: always
|
|
environment:
|
|
- PMA_ARBITRARY=1
|
|
ports:
|
|
- ${PHPMYADMIN_PORT}:80
|
|
depends_on:
|
|
- database
|
|
postgres:
|
|
image: postgres:${POSTGRES_VERSION}
|
|
environment:
|
|
- POSTGRES_USER=root
|
|
- POSTGRES_PASSWORD=aA123456!
|
|
ports:
|
|
- ${POSTGRES_PORT}:5432
|
|
volumes:
|
|
- ./data/postgres:/var/lib/postgresql/data
|
|
|