-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
71 lines (69 loc) · 1.39 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
67
68
69
70
71
db:
image: postgres:9.4
env_file: .env
ports:
- "5432:5432"
redis:
image: redis:2.8.21
rabbitmq:
build: docker/rabbitmq/
ports:
- "5672:5672"
- "15672:15672" # here, we can access rabbitmq management plugin
- "15674:15674" # stomp
web:
build: .
env_file: .env
environment:
- PYTHONUNBUFFERED=1
- BROKER_URL=amqp://guest:guest@rabbitmq//
command: bash -c "while true; do sleep 3; python manage.py runserver 0.0.0.0:8080; done"
working_dir: /app
volumes:
- .:/app
ports:
- "8080:8080"
links:
- db:db
- rabbitmq:rabbitmq
- redis:redis
worker:
build: .
env_file: .env
environment:
- PYTHONUNBUFFERED=1
- C_FORCE_ROOT=true
- BROKER_URL=amqp://guest:guest@rabbitmq//
command: bash -c "while true; do sleep 3; celery -A config.celery worker; done"
working_dir: /app
volumes:
- .:/app
links:
- db:db
- rabbitmq:rabbitmq
- redis:redis
flower:
build: .
env_file: .env
environment:
- PYTHONUNBUFFERED=1
- C_FORCE_ROOT=true
- BROKER_URL=amqp://guest:guest@rabbitmq//
command: bash -c "while true; do sleep 3; celery -A config.celery flower --port=5555; done"
working_dir: /app
volumes:
- .:/app
ports:
- "5555:5555"
links:
- db:db
- rabbitmq:rabbitmq
- redis:redis
nginx:
build: docker/nginx
volumes_from:
- web
ports:
- "80:80"
links:
- web:web