-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose-prod.yml
43 lines (42 loc) · 985 Bytes
/
docker-compose-prod.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
version: "3.9"
services:
web:
image: nginx
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf:ro
- ./frontend:/frontend
- ./deploy.sh:/usr/bin/
ports:
- "8001:80"
command:
- /frontend/deploy.sh
db:
image: postgres
environment:
- POSTGRES_DB=scrabble
- POSTGRES_USER=scrabble
- POSTGRES_PASSWORD=scrabble
healthcheck:
test: ["CMD-SHELL", "pg_isready -U scrabble"]
interval: 5s
timeout: 5s
retries: 5
backend:
build: .
command: "watchmedo auto-restart --directory='./' --ignore-patterns='.*/.venv.*' --pattern='*.py' --recursive -- python manage.py runserver 0.0.0.0:8000"
volumes:
- .:/app/
ports:
- "8000:8000"
depends_on:
db:
condition: service_healthy
node:
build: ./frontend
environment:
- NODE_ENV=development
volumes:
- ./frontend:/home/node/app
ports:
- "8080:8080"
command: "yarn serve"