-
Notifications
You must be signed in to change notification settings - Fork 0
/
compose.yml
65 lines (61 loc) · 1.64 KB
/
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
services:
app:
build: .
ports:
- 8000:8000
environment:
DJANGO_SETTINGS_MODULE: polarrouteserver.settings.development
CELERY_BROKER_URL: amqp://guest:guest@rabbitmq
POLARROUTE_MESH_DIR: /usr/src/app/mesh
POLARROUTE_DB_HOST: db
POLARROUTE_DB_PORT: 5432
entrypoint: /usr/src/app/entrypoint.sh
command: ["python", "manage.py", "runserver", "0.0.0.0:8000"]
volumes:
- ./manage.py:/usr/src/app/manage.py
- ./polarrouteserver:/usr/src/app/polarrouteserver
- ./data/mesh:/usr/src/app/data/mesh
depends_on:
- db
- celery
db:
image: postgres:16
restart: always
environment:
POSTGRES_USER: polarroute
POSTGRES_PASSWORD: polarroute
POSTGRES_DB: polarroute
PGDATA: /var/lib/postgresql/data/pgdata
volumes:
- ./data/db:/var/lib/postgresql/data
ports:
- 5432:5432
celery:
build: .
environment:
DJANGO_SETTINGS_MODULE: polarrouteserver.settings.development
CELERY_BROKER_URL: amqp://guest:guest@rabbitmq
POLARROUTE_MESH_DIR: /usr/src/app/mesh
POLARROUTE_DB_HOST: db
POLARROUTE_DB_PORT: 5432
command: ["celery", "-A", "polarrouteserver", "worker", "--loglevel=info"]
volumes:
- ./polarrouteserver:/usr/src/app/polarrouteserver
depends_on:
- db
- rabbitmq
rabbitmq:
image: rabbitmq
ports:
- 5672:5672
- 15672:15672
swagger:
profiles: ['swagger']
image: swaggerapi/swagger-ui
ports:
- "80:8080"
environment:
- SWAGGER_JSON=/app/schema.yml
- BASE_URL=/swagger
volumes:
- ./schema.yml:/app/schema.yml