-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
43 lines (40 loc) · 1002 Bytes
/
docker-compose.yml
File metadata and controls
43 lines (40 loc) · 1002 Bytes
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
version: "3.9"
services:
api:
build:
context: .
dockerfile: Dockerfile
container_name: rest_mailing
volumes:
- .:/app
command: bash -lc "uvicorn rest.api:app --host 0.0.0.0 --port 6245"
environment:
- PYTHONUNBUFFERED=1
- CELERY_BROKER_URL=amqp://guest:guest@rabbitmq:5672//
- CELERY_RESULT_BACKEND=rpc://
ports:
- "6245:6245"
depends_on:
- rabbitmq
rabbitmq:
image: rabbitmq:3-management
container_name: rabbitmq
ports:
- "5672:5672"
- "15672:15672"
environment:
RABBITMQ_DEFAULT_USER: guest
RABBITMQ_DEFAULT_PASS: guest
celery_worker:
build:
context: .
dockerfile: Dockerfile
container_name: celery_worker
command: bash -lc "celery -A mailing.tasks.celery_app worker -l info"
volumes:
- .:/app
environment:
- CELERY_BROKER_URL=amqp://guest:guest@rabbitmq:5672//
- CELERY_RESULT_BACKEND=rpc://
depends_on:
- rabbitmq