-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompose.prod.yaml
More file actions
95 lines (86 loc) · 2.05 KB
/
Copy pathcompose.prod.yaml
File metadata and controls
95 lines (86 loc) · 2.05 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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
services:
authsvc-build:
build:
context: ./auth-svc
image: authsvc-prod:latest
command : ["bun", "run", "prisma-pro", "migrate", "deploy"]
environment:
- DOTENV_PRIVATE_KEY_PRODUCTION
networks:
- authnet
depends_on:
db-authsvc:
condition: service_healthy
authsvc:
image: authsvc-prod:latest
environment:
- DOTENV_PRIVATE_KEY_PRODUCTION
networks:
- authnet
- svcnet
depends_on:
authsvc-build:
condition: service_completed_successfully
db-authsvc:
image: postgres:alpine
environment:
- POSTGRES_PASSWORD=${AUTH_DB_PASS}
- POSTGRES_USER=${AUTH_DB_USER}
- POSTGRES_DB=${AUTH_DB}
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $$POSTGRES_USER -d $$POSTGRES_DB"]
interval: 3s
timeout: 3s
retries: 3
networks:
- authnet
volumes:
- authsvc-data-prod:/var/lib/postgresql
userpost-build:
build:
context: ./post-svc
image: userpost-prod:latest
command : ["bun", "run", "postbuild-pro"]
environment:
- DOTENV_PRIVATE_KEY_PRODUCTION
networks:
- frontnet
depends_on:
authsvc:
condition: service_started
db-userpost:
condition: service_healthy
userposts:
image: userpost-prod:latest
ports:
- 3000:3000
environment:
- DOTENV_PRIVATE_KEY_PRODUCTION
networks:
- frontnet
- svcnet
depends_on:
userpost-build:
condition: service_completed_successfully
db-userpost:
image: postgres:alpine
environment:
- POSTGRES_PASSWORD=${POST_DB_PASS}
- POSTGRES_USER=${POST_DB_USER}
- POSTGRES_DB=${POST_DB}
healthcheck:
test: ["CMD-SHELL", "pg_isready -U $$POSTGRES_USER -d $$POSTGRES_DB"]
interval: 3s
timeout: 3s
retries: 3
networks:
- frontnet
volumes:
- userpost-data-prod:/var/lib/postgresql
networks:
frontnet:
authnet:
svcnet:
volumes:
userpost-data-prod:
authsvc-data-prod: