-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.prod.yml
90 lines (88 loc) · 1.8 KB
/
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
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
version: '3.8'
services:
web:
build:
context: .
dockerfile: Dockerfile.prod
command: bash -c "./run_web_service.sh"
volumes:
- static_volume:/home/vsf/web/staticfiles
expose:
- 8000
env_file:
- ./.env.prod
depends_on:
- db
- scrapyd
scrapyd:
build:
context: .
dockerfile: scrapyd/Dockerfile
ports:
- "6800:6800"
volumes:
- ./data:/var/lib/scrapyd
hostname: scrapyd
env_file:
- ./.env.prod
restart: unless-stopped
db:
image: postgres:13.0-alpine
volumes:
- postgres_data:/var/lib/postgresql/data/
env_file:
- ./.env.prod.db
hostname: postgres
nginx:
image: nginx:latest
volumes:
- static_volume:/home/vsf/web/staticfiles
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
ports:
- 1337:80
- 5555:5555
depends_on:
- web
- flower
hostname: nginx
redis:
image: redis:alpine
expose:
- 6379
celery:
build:
context: .
dockerfile: Dockerfile.prod
command: celery -A noticias_sin_filtro_server worker -l info -s /tmp/celerybeat-schedule
volumes:
- ./:/home/vsf/web
env_file:
- .env.prod
depends_on:
- redis
restart: unless-stopped
celery-beat:
build:
context: .
dockerfile: Dockerfile.prod
command: celery -A noticias_sin_filtro_server beat -l info -s /tmp/celerybeat-schedule
volumes:
- ./:/home/vsf/web
env_file:
- .env.prod
depends_on:
- redis
restart: unless-stopped
flower:
image: mher/flower
command: celery flower --broker=redis://redis:6379/0 --port=5555
ports:
- 5557:5555
depends_on:
- redis
expose:
- 5555
hostname: flower
volumes:
postgres_data:
static_volume: