-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
66 lines (60 loc) · 1.76 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.1'
services:
postgres:
image: postgres:15
ports:
- "${DOCKER_POSTGRES_PORT_FORWARD-5432}:5432"
volumes:
- ${PGDATA-./.data/db}:/var/lib/postgresql/data
environment:
POSTGRES_USER: "${POSTGRES_USER-postgres}"
POSTGRES_PASSWORD: "${POSTGRES_PASSWORD-postgres}"
POSTGRES_DB: "${POSTGRES_DB-postgres}"
rabbitmq:
image: rabbitmq:3.11.9-management
ports:
- "${DOCKER_RABBITMQ_PORT_FORWARD-5672}:5672"
- "${DOCKER_RABBITMQ_MANAGEMENT_PORT_FORWARD-15672}:15672"
environment:
RABBITMQ_DEFAULT_USER: "${RABBITMQ_DEFAULT_USER-guest}"
RABBITMQ_DEFAULT_PASS: "${RABBITMQ_DEFAULT_PASS-guest}"
RABBITMQ_DEFAULT_VHOST: "${RABBITMQ_DEFAULT_VHOST}"
django: &django
stdin_open: true
tty: true
build: .
command: /app/docker-init.sh
volumes:
- ./:/app
ports:
- "${DOCKER_DJANGO_PORT_FORWARD-8000}:8000"
depends_on:
- postgres
- rabbitmq
environment:
POSTGRES_USER: "${POSTGRES_USER-postgres}"
POSTGRES_PASSWORD: "${POSTGRES_PASSWORD-postgres}"
POSTGRES_DB: "${POSTGRES_DB-postgres}"
POSTGRES_HOST: "${POSTGRES_HOST-postgres}"
POSTGRES_PORT: "${POSTGRES_PORT-5432}"
CELERY_BROKER_URL: "${CELERY_BROKER_URL-amqp://guest:guest@rabbitmq:5672/}"
celery-beat:
<<: *django
depends_on:
- postgres
- rabbitmq
ports: []
command: celery beat --loglevel DEBUG
celery-worker:
<<: *django
ports: []
command: celery worker --loglevel DEBUG
flower:
image: mher/flower
ports:
- "${DOCKER_FLOWER_PORT_FORWARD-5555}:5555"
command: celery flower
depends_on:
- rabbitmq
environment:
CELERY_BROKER_URL: "${CELERY_BROKER_URL-amqp://guest:guest@rabbitmq:5672/}"