-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
63 lines (57 loc) · 1.27 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
version: "3"
services:
rabbitmq:
image: "rabbitmq:3-management-alpine"
env_file: docker/rabbitmq/.env
ports:
- "4369:4369"
- "5672:5672"
- "25672:25672"
- "15672:15672"
volumes:
- "rabbitmq_data:/var/lib/rabbitmq"
- "./docker/rabbitmq/rabbitmq.conf:/etc/rabbitmq/rabbitmq.conf"
redis:
build: ./docker/redis
env_file: docker/redis/.env
ports:
- "6379:6379"
volumes:
- "redis_data:/data"
flower:
image: jcpaiva/celery-flower:latest
env_file: docker/flower/.env
ports:
- "5555:5555"
depends_on:
- rabbitmq
- redis
api:
build:
context: .
dockerfile: ./docker/api/Dockerfile
env_file: docker/api/.env
ports:
- "8000:8000"
depends_on:
- rabbitmq
- redis
volumes:
- "./app/:/app"
command: "poetry run hypercorn app/main:app --bind 0.0.0.0:8000 --reload"
worker:
build:
context: .
dockerfile: ./docker/api/Dockerfile
env_file: docker/worker/.env
depends_on:
- rabbitmq
- redis
volumes:
- "./app/:/app"
command: "poetry run celery worker -A app.worker.celery_worker -l info -Q test-queue -c 1"
volumes:
rabbitmq_data:
driver: local
redis_data:
driver: local