-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
41 lines (39 loc) · 990 Bytes
/
docker-compose.yml
File metadata and controls
41 lines (39 loc) · 990 Bytes
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
services:
postgres:
image: postgis/postgis:15-3.4
container_name: sadakai_db
environment:
POSTGRES_USER: sadakai
POSTGRES_PASSWORD: sadakai_secret
POSTGRES_DB: sadakai
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U sadakai"]
interval: 10s
timeout: 5s
retries: 5
api:
build:
context: ./api
dockerfile: Dockerfile
container_name: sadakai_api
environment:
DATABASE_URL: postgresql://sadakai:sadakai_secret@postgres:5432/sadakai
R2_ENDPOINT: ${R2_ENDPOINT}
R2_ACCESS_KEY: ${R2_ACCESS_KEY}
R2_SECRET_KEY: ${R2_SECRET_KEY}
R2_BUCKET: ${R2_BUCKET}
API_KEY: ${API_KEY}
MODEL_PATH: /app/weights/best.pt
ports:
- "8000:8000"
depends_on:
postgres:
condition: service_healthy
volumes:
- ./model/weights:/app/weights
volumes:
postgres_data: