-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
52 lines (40 loc) · 911 Bytes
/
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
version: '3.8'
services:
djangoserver:
build: .
command: python manage.py runserver 0.0.0.0:8000
ports:
- "8000:8000"
container_name: Backend
volumes:
- .:/app
depends_on:
- redis
redis:
image: redis:7.2.3-alpine3.18
container_name: redisserver
celery:
image: celery:4.0.2
container_name: celeryserver
build: .
depends_on:
- redis
- djangoserver
volumes:
- .:/app
command: celery -A project worker --loglevel=info
environment:
- CELERY_BROKER_URL = 'redis://redis:6379/0'
- CELERY_BACKEND_RESULT = 'redis://redis:6379/0'
db:
image: postgres:latest
ports:
- "5432:5432"
environment:
- POSTGRES_USER=postgres
- POSTGRES_DB=mehyar
- POSTGRES_PASSWORD=postgres
volumes:
- postgres_data:/var/lib/postgres/data
volumes:
postgres_data: