-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
50 lines (48 loc) · 1.22 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
---
name: winterthur
services:
app:
build: .
image: "rrchnm/winterthur"
ports:
- 8000:8000
volumes:
- dj-data:/app
environment:
- DEBUG=True
- DJANGO_SECRET_KEY=thisisnotasecretkey
- DJANGO_ALLOWED_HOSTS=localhost
- DJANGO_CSRF_TRUSTED_ORIGINS=http://localhost
- DB_HOST=db
- DB_PORT=5432
- DB_NAME=winterthur
- DB_USER=winterthur
- DB_PASSWORD=password
- OBJ_STORAGE=True
- OBJ_STORAGE_ACCESS_KEY_ID=test-key-id
- OBJ_STORAGE_SECRET_ACCESS_KEY=test-secret-key
- OBJ_STORAGE_BUCKET_NAME=test
- OBJ_STORAGE_ENDPOINT_URL=http://10.112.113.212:8000
command: >
sh -c "poetry run python3 manage.py migrate &&
poetry run python3 manage.py runserver 0.0.0.0:8000"
depends_on:
db:
condition: service_healthy
db:
image: postgres:16
volumes:
- pg-data:/var/lib/postgresql/data
environment:
- POSTGRES_DB=winterthur
- POSTGRES_USER=winterthur
- POSTGRES_PASSWORD=password
- POSTGRES_HOST=db
healthcheck:
test: ["CMD-SHELL", "pg_isready -U winterthur"]
interval: 2s
timeout: 5s
retries: 3
volumes:
pg-data:
dj-data: