-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
66 lines (60 loc) · 1.37 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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
version: '3.8'
services:
backend:
build:
dockerfile: ./compose/backend/Dockerfile
context: .
command: bash -c "alembic upgrade head && uvicorn --port 8000 --host 0.0.0.0 app.main:app"
env_file:
- .env
volumes:
- ./data:/data
- ./mounts/media:/app/media
depends_on:
- db
dramatiq:
build:
dockerfile: ./compose/backend/Dockerfile
context: .
command: bash -c "dramatiq app.tasks"
env_file:
- .env
volumes:
- ./data:/data
- ./mounts/media:/app/media
depends_on:
- backend
- db
- broker
broker:
image: rabbitmq:3.8-management-alpine
environment:
- RABBITMQ_DEFAULT_USER=${BROKER_USER}
- RABBITMQ_DEFAULT_PASS=${BROKER_PASS}
restart: unless-stopped
db:
image: postgres:14
env_file:
- .env
volumes:
- ./db:/var/lib/postgresql/data
frontend:
build:
dockerfile: ./compose/frontend/Dockerfile
context: .
restart: unless-stopped
nginx:
build:
dockerfile: ./compose/nginx/Dockerfile
context: .
restart: unless-stopped
depends_on:
- backend
- frontend
ports:
- 127.0.0.1:${HTTP_PORT}:80
volumes:
- ./mounts/uwsgi:/uwsgi
- ./mounts/logs/nginx:/var/log/nginx
- ./mounts/media:/webapp/media:ro
- ./mounts/static:/webapp/static:ro