-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
73 lines (66 loc) · 1.58 KB
/
docker-compose.yml
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
services:
nginx:
container_name: 8fit-proxy
build:
context: ./nginx
dockerfile: Dockerfile
image: 8fit-proxy:1.0.0-compose
ports:
- "80:80"
networks:
- 8Fit-network
depends_on:
web-application-server:
condition: service_healthy
postgresdb:
container_name: 8fit-db
build:
context: ./postgresDB
dockerfile: Dockerfile
image: 8fit-db:1.0.0-compose
environment:
POSTGRES_USER: ${DB_USERNAME}
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_DB: ${DB_NAME}
healthcheck:
test: [ "CMD-SHELL", "psql -U ${DB_USERNAME} -d ${DB_NAME} -c 'SELECT 1;' || exit 1" ]
interval: 5s
retries: 5
timeout: 10s
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
networks:
- 8Fit-network
web-application-server:
container_name: 8fit-was
build:
context: ./web-application-server
dockerfile: Dockerfile
image: 8fit-was:1.0.0-compose
env_file:
- .env
depends_on:
postgresdb:
condition: service_healthy
healthcheck:
test: [ "CMD-SHELL", "curl -f http://localhost:8080/api/v1/health || exit 1" ]
interval: 10s
retries: 5
timeout: 5s
networks:
- 8Fit-network
image-classification-worker:
container_name: 8fit-image-worker
build:
context: ./image-classification-worker
dockerfile: Dockerfile
image: 8fit-image-worker:1.0.0-compose
networks:
- 8Fit-network
volumes:
postgres_data:
networks:
8Fit-network:
driver: bridge