-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
53 lines (44 loc) · 1020 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
53
version: '3.8'
services:
redis:
image: redis:7.0.11
web:
container_name: roshan_api
build: .
command: python manage.py runserver 0.0.0.0:8000
volumes:
- .:/app
ports:
- "8001:8000"
environment:
- DEBUG=1
- ALLOWED_HOSTS=localhost, 127.0.0.1, 0.0.0.0
- DATABASE_URL=sqlite:///db.sqlite3
networks:
- default
celery:
container_name: celery
build: .
command: celery --app=api worker -l INFO
volumes:
- .:/app
environment:
- DEBUG=1
- ALLOWED_HOSTS=localhost, 127.0.0.1, 0.0.0.0
- DATABASE_URL=sqlite:///db.sqlite3
depends_on:
- redis
beat:
container_name: beat
build: .
command: celery --app=api beat -l INFO --scheduler django_celery_beat.schedulers:DatabaseScheduler
volumes:
- .:/app
depends_on:
- redis
- web
# volumes:
# db_data: # This will persist the SQLite database in Docker volume if needed
networks:
default:
driver: bridge