-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
52 lines (47 loc) · 923 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'
services:
web:
build:
context: .
dockerfile: Dockerfile
ports:
- '8000:8000'
restart: on-failure
depends_on:
- db
- redis
- worker
volumes:
- .:/app
db:
image: postgres
ports:
- "5432:5432"
environment:
- POSTGRES_DB=Newsapp
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=password
redis:
image: redis
worker:
build:
context: .
dockerfile: Dockerfile
command: celery -A newsaggregator worker --loglevel=info
volumes:
- .:/app
restart: on-failure
depends_on:
- db
- redis
beat:
build:
context: .
dockerfile: Dockerfile
command: celery -A newsaggregator beat --loglevel=INFO --scheduler django_celery_beat.schedulers:DatabaseScheduler
volumes:
- .:/app
restart: on-failure
depends_on:
- db
- redis