-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
50 lines (49 loc) · 1.13 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
version: '3'
services:
redis:
image: redis:latest
ports:
- 6379:6379
db:
image: postgres
environment:
- POSTGRES_DB=postgres
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:7.4.0
environment:
- cluster.name=docker-cluster
- discovery.type=single-node
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- xpack.security.enabled=false
volumes:
- /elasticsearch.yml
ports:
- 9200:9200
web:
build: .
command: bash -c "python manage.py makemigrations && python manage.py migrate && python manage.py runserver 0.0.0.0:8000"
container_name: contact_trace
volumes:
- .:/code
ports:
- "8000:8000"
depends_on:
- db
celery:
build: .
command: celery -A contact_trace worker --beat --scheduler django --loglevel=info
volumes:
- .:/code
depends_on:
- db
- redis
celery-beat:
build: .
command: celery -A contact_trace beat -l info --pidfile=/tmp/celeryd.pid
volumes:
- .:/code
depends_on:
- db
- redis