Repository navigation
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
76 lines (71 loc) · 1.73 KB
/
Copy pathdocker-compose.yml
File metadata and controls
76 lines (71 loc) · 1.73 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
version: '3.8'
services:
nginx:
image: nginx:latest
ports:
- "80:80"
- "443:443"
volumes:
- ./nginx:/etc/nginx/conf.d
# For SSL certificates (when you have them)
# - /etc/letsencrypt:/etc/letsencrypt
depends_on:
- backend
networks:
- app-network
restart: unless-stopped
backend:
build: ./backend
container_name: neopromisance-backend
expose:
- "3000"
depends_on:
- db
volumes:
- ./backend/src:/app/src
- ./backend/build:/app/build
environment:
- NODE_ENV=production
- DB_DIALECT=postgres
- DB_HOST=db
- DB_PORT=5432
- DB_USERNAME=hokies
- DB_PASSWORD=hokies
- DB_DATABASE=promisance
# Google Authentication
- GOOGLE_CLIENT_ID=${GOOGLE_CLIENT_ID}
- GOOGLE_CLIENT_SECRET=${GOOGLE_CLIENT_SECRET}
# Other important environment variables
- JWT_SECRET=${JWT_SECRET}
- PORT=3000
- ORIGIN=${ORIGIN}
- ALTORIGIN=${ALTORIGIN}
- DOMAIN=${DOMAIN}
- GAME_RESET=${GAME_RESET}
- CRON_SECRET=${CRON_SECRET}
# Sentry error/perf reporting. Unset = disabled (no events sent).
- SENTRY_DSN=${SENTRY_DSN}
restart: unless-stopped
networks:
- app-network
db:
image: postgres:16-alpine
volumes:
- postgres_data:/var/lib/postgresql/data
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POSTGRES_DB=promisance
restart: unless-stopped
networks:
- app-network
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d promisance"]
interval: 10s
timeout: 5s
retries: 5
networks:
app-network:
driver: bridge
volumes:
postgres_data: