70 lines
1.6 KiB
YAML
70 lines
1.6 KiB
YAML
version: '3.9'
|
|
name: y9-dev-environments
|
|
services:
|
|
db:
|
|
image: mysql:latest
|
|
container_name: mysql01
|
|
restart: always
|
|
extra_hosts:
|
|
- "host.docker.internal:host-gateway"
|
|
networks:
|
|
- y9-share-net
|
|
ports:
|
|
- "3306:3306"
|
|
command: --default-authentication-plugin=caching_sha2_password
|
|
environment:
|
|
MYSQL_ROOT_PASSWORD: '12345678'
|
|
MYSQL_DATABASE: 'y9_public'
|
|
volumes:
|
|
- d:/docker-data/mysql:/var/lib/mysql
|
|
- d:/docker-config/mysql-init:/docker-entrypoint-initdb.d
|
|
healthcheck:
|
|
#test: [ "CMD", "mysqladmin" ,"ping", "-h", "localhost" ]
|
|
test: "mysql --user=root --password=12345678 --execute='show databases;'"
|
|
interval: 5s
|
|
timeout: 10s
|
|
retries: 8
|
|
|
|
redis:
|
|
image: redis:latest
|
|
container_name: redis01
|
|
restart: always
|
|
extra_hosts:
|
|
- "host.docker.internal:host-gateway"
|
|
networks:
|
|
- y9-share-net
|
|
ports:
|
|
- "6379:6379"
|
|
command: redis-server --requirepass "12345678"
|
|
volumes:
|
|
- d:/docker-data/redis:/data
|
|
|
|
consul:
|
|
image: docker.io/bitnami/consul:latest
|
|
container_name: consul01
|
|
restart: always
|
|
extra_hosts:
|
|
- "host.docker.internal:host-gateway"
|
|
networks:
|
|
- y9-share-net
|
|
environment:
|
|
- CONSUL_AGENT_MODE=server
|
|
- CONSUL_BOOTSTRAP_EXPECT=1
|
|
- CONSUL_ENABLE_UI=true
|
|
- CONSUL_HTTP_PORT_NUMBER=8500
|
|
ports:
|
|
#- '8300:8300'
|
|
#- '8301:8301'
|
|
#- '8301:8301/udp'
|
|
- '8500:8500'
|
|
#- '8600:8600'
|
|
#- '8600:8600/udp'
|
|
volumes:
|
|
- d:/docker-data/consul:/bitnami/consul
|
|
|
|
networks:
|
|
y9-share-net:
|
|
external: true
|
|
|
|
|