-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
80 lines (75 loc) · 1.66 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
71
72
73
74
75
76
77
78
79
80
version: '3'
services:
dbauth:
image: postgres:latest
restart: always
ports:
- '5433:5432'
environment:
- POSTGRES_PASSWORD=example
- POSTGRES_DB=postgres
- POSTGRES_USER=postgres
healthcheck:
test: ['CMD', 'pg_isready', '-U', 'postgres']
interval: 10s
timeout: 5s
retries: 5
volumes:
- ./auth-service/src/database/data:/var/lib/postgresql/data
redis:
image: redis:latest
restart: always
ports:
- '6379:6379'
healthcheck:
test: ['CMD', 'redis-cli', 'ping']
interval: 10s
timeout: 5s
retries: 5
auth:
build: ./auth-service
depends_on:
dbauth:
condition: service_healthy
redis:
condition: service_started
restart: always
ports:
- '1111:1111'
env_file:
- ./auth-service/.env
dbbackend:
image: postgres:latest
restart: always
ports:
- '5434:5432'
environment:
- POSTGRES_PASSWORD=password
- POSTGRES_DB=postgres
- POSTGRES_USER=postgres
volumes:
- ./backend-dday/src/database/data:/var/lib/postgresql/data
healthcheck:
test: ['CMD', 'pg_isready', '-U', 'postgres']
interval: 10s
timeout: 5s
retries: 5
# backend-migration:
# build: ./backend-migrations
# depends_on:
# dbbackend:
# condition: service_healthy
# environment:
# - NODE_ENV=docker
backend:
build: ./backend-dday
depends_on:
dbbackend:
condition: service_healthy
restart: always
ports:
- '2222:2222'
volumes:
- ./backend-dday/:/app/
env_file:
- ./backend-dday/.env.docker