-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
45 lines (42 loc) · 1 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
version: "3"
services:
api:
build:
context: .
dockerfile: ./docker/api/Dockerfile
environment:
NODE_ENV: production
SALT_ROUNDS: ${SALT_ROUNDS}
ALLOWED_ORIGIN: ${ALLOWED_ORIGIN}
SESSION_SECRET: ${SESSION_SECRET}
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
STRIPE_SECRET_KEY: ${STRIPE_SECRET_KEY}
STRIPE_WEBHOOK_SECRET_KEY: ${STRIPE_WEBHOOK_SECRET_KEY}
depends_on:
- db
ports:
- 8080:8080
deploy:
restart_policy:
condition: on-failure
max_attempts: 5
window: 1s
db:
build:
context: .
dockerfile: ./docker/db/Dockerfile
args:
POSTGRES_USER: ${POSTGRES_USER}
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
volumes:
- db_data:/var/lib/postgresql/data
deploy:
restart_policy:
condition: on-failure
max_attempts: 5
window: 1s
volumes:
db_data: