-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
70 lines (64 loc) · 1.35 KB
/
docker-compose.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
version: '3'
services:
router-service:
image: router:latest
volumes:
- ./router/schema:/dist/config
depends_on:
- security-service
- example-service
- mysql
# restart: on-failure
networks:
- app_network
extra_hosts:
- "host.docker.internal:host-gateway"
security-service:
image: security:local
ports:
- "4000:4000"
networks:
- app_network
extra_hosts:
- "host.docker.internal:host-gateway"
example-service:
image: example:local
ports:
- "4001:4001"
volumes:
- ./example_storage:/root/storage
networks:
- app_network
environment:
- SHOW_CALLER=false
- DB_HOST=mysql
- DB_PORT=3306
- DB_USER=myuser
- DB_PASSWORD=mypassword
- DB_DATABASE=example
depends_on:
mysql:
condition: service_healthy
mysql:
image: mysql:latest
ports:
- "3306:33061"
environment:
- MYSQL_ROOT_PASSWORD=LTYlty0123
- MYSQL_DATABASE=example
- MYSQL_USER=myuser
- MYSQL_PASSWORD=mypassword
volumes:
- mysql_data:/var/lib/mysql
networks:
- app_network
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
interval: 10s
timeout: 5s
retries: 5
networks:
app_network:
driver: bridge
volumes:
mysql_data: