-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
75 lines (71 loc) · 1.61 KB
/
docker-compose.yml
File metadata and controls
75 lines (71 loc) · 1.61 KB
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
71
72
73
74
75
version: "3.8"
services:
back-end:
image: back-end:v1
build:
context: ./Medicine-Web
dockerfile: Dockerfile
container_name: back-end
restart: always
depends_on:
- db
networks:
- db-network
- app-network
ports:
- "8080:8080"
# healthcheck:
# test: ["CMD-SHELL", "curl -f http://localhost:8080 || exit 1"]
# interval: 30s
# timeout: 10s
# retries: 3
front-end:
image: front-end:v1
build:
context: ./Medicine-Web-FE
dockerfile: Dockerfile
restart: always
ports:
- "8900:80"
depends_on:
- back-end
networks:
- app-network
healthcheck:
test: ["CMD-SHELL", "curl -f http://localhost:8900 || exit 1"]
interval: 30s
timeout: 10s
retries: 3
db:
image: database:v1
build:
context: ./Database
dockerfile: Dockerfile.Database
container_name: db
restart: always
environment:
- SA_PASSWORD=${SA_PASSWORD}
- ACCEPT_EULA=${ACCEPT_EULA}
volumes:
- db_data:/var/opt/mssql/data
ports:
- "1433:1433"
networks:
- db-network
healthcheck:
test:
[
"CMD-SHELL",
"chmod +x /dbconfig/health_check.sh & ./dbconfig/health_check.sh",
]
interval: 30s
timeout: 10s
retries: 3
# docker exec -it db /opt/mssql-tools/bin/sqlcmd -S localhost -U sa -P DatLaid234555@Xy
networks:
db-network:
driver: bridge
name: db-network
app-network:
driver: bridge
name: app-network