-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
42 lines (40 loc) · 1 KB
/
docker-compose.yml
File metadata and controls
42 lines (40 loc) · 1 KB
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
version: '3.8'
services:
disaster-mapping-api:
build: .
container_name: disaster-mapping-segmentation
ports:
- "8080:8080"
volumes:
- ./data:/app/data
- ./app/static:/app/app/static
environment:
- APP_NAME=AI Disaster Mapping API
- DEBUG=true
- MODEL_PATH=app/models/sam_vit_h_4b8939.pth
- MODEL_TYPE=vit_h
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8080/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 60s
# Optional: Add a reverse proxy (uncomment if needed)
# nginx:
# image: nginx:alpine
# container_name: disaster-mapping-nginx
# ports:
# - "80:80"
# volumes:
# - ./nginx.conf:/etc/nginx/nginx.conf
# depends_on:
# - disaster-mapping-api
# restart: unless-stopped