-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
26 lines (26 loc) · 1.54 KB
/
Copy pathdocker-compose.yml
File metadata and controls
26 lines (26 loc) · 1.54 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
services:
dashboard:
build: .
image: wildlife-dashboard:latest
container_name: wildlife-dashboard
restart: unless-stopped
ports:
- "8080:8080"
volumes:
# Whole project lives under one path on the 2TB drive; mount it at the
# same absolute path inside the container so config's paths resolve.
- ${WILDLIFE_ROOT:-/mnt/wildlife/wildlife-pipeline}:${WILDLIFE_ROOT:-/mnt/wildlife/wildlife-pipeline}
# Serve the dashboard app + templates live from the host. The app loads from
# the baked /app copy (editable install), so without these a code/template
# edit needs a full image rebuild. Mounting the file + dir makes edits live
# (templates per-request; app.py on container restart). static/ stays baked
# so the import-time mkdir keeps working on the read-only mount.
- ${WILDLIFE_ROOT:-/mnt/wildlife/wildlife-pipeline}/src/wildlife/dashboard/app.py:/app/src/wildlife/dashboard/app.py:ro
- ${WILDLIFE_ROOT:-/mnt/wildlife/wildlife-pipeline}/src/wildlife/dashboard/axis.py:/app/src/wildlife/dashboard/axis.py:ro
- ${WILDLIFE_ROOT:-/mnt/wildlife/wildlife-pipeline}/src/wildlife/dashboard/templates:/app/src/wildlife/dashboard/templates:ro
# Match the host timezone (container is UTC by default; host is local).
- /etc/localtime:/etc/localtime:ro
environment:
WILDLIFE_CONFIG: ${WILDLIFE_ROOT:-/mnt/wildlife/wildlife-pipeline}/config.yaml
# use host bryan's uid:gid so config edits land with correct ownership
user: "${WILDLIFE_UID:-1000}:${WILDLIFE_GID:-1000}"