-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
67 lines (65 loc) · 1.63 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
67
# -------------------------------
# Rudimentary docker-compose for local testing
# "docker-compose up" should run a web service at:
# http://0.0.0.0:8080/
# -------------------------------
version: '3'
services:
# -------------------------------
# Redis
# -------------------------------
redis:
image: redis:4.0
hostname: redis
volumes:
- app-volume:/tmp
ports:
- '6379:6379'
# -------------------------------
# Django web server
# -------------------------------
web:
build:
context: .
dockerfile: Dockerfile-web
hostname: web
environment:
- DJANGO_DEBUG=true
- DJANGO_SETTINGS_MODULE=ravens_metadata.settings.docker_test_settings
- REDIS_HOST=redis
- PREPROCESS_DATA_DIR=/raven_metadata
- EDITOR_URL=
#command: python manage.py runserver 8080
volumes:
- app-volume:/tmp
- preprocess-volume:/raven_metadata
ports:
- "8080:8080"
# set up links so that web knows about db, rabbit and redis
links:
- celery_queue
- redis
depends_on:
- celery_queue
# -------------------------------
# Celery worker
# -------------------------------
celery_queue:
build:
context: .
dockerfile: Dockerfile-web
command: celery -A ravens_metadata worker -l info
environment:
- DJANGO_SETTINGS_MODULE=ravens_metadata.settings.docker_test_settings
- REDIS_HOST=redis
- PREPROCESS_DATA_DIR=/raven_metadata
volumes:
- app-volume:/tmp
- preprocess-volume:/raven_metadata
links:
- redis
depends_on:
- redis
volumes:
app-volume:
preprocess-volume: