-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
58 lines (52 loc) · 1.07 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
version: "3.8"
services:
db:
image: postgres
volumes:
- ./backend/pg_data:/var/lib/postgresql/data
environment:
- POSTGRES_DB=postgres
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
container_name: postgres_db
redis:
image: redis:alpine
django:
build: ./backend
volumes:
- ./backend:/app
- static_files:/app/staticfiles
expose:
- 8000
command: gunicorn backend.wsgi --bind 0.0.0.0:8000
depends_on:
- db
celery:
restart: always
build: ./backend
volumes:
- ./backend:/app
command: celery -A backend worker -l INFO
depends_on:
- db
- redis
- django
react:
build:
context: ./frontend
volumes:
- react_build:/app/build
nginx:
build: ./nginx
ports:
- 80:80
volumes:
- ./nginx/nginx-setup.conf:/etc/nginx/conf.d/default.conf:ro
- react_build:/var/www/react
- static_files:/var/www/django/staticfiles
depends_on:
- django
- react
volumes:
react_build:
static_files: