Repository navigation
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
52 lines (52 loc) · 2.83 KB
/
Copy pathdocker-compose.yml
File metadata and controls
52 lines (52 loc) · 2.83 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
43
44
45
46
47
48
49
50
51
52
services:
yuvomi:
image: ghcr.io/ulsklyc/yuvomi:latest
build: . # optional: use --build to build locally instead
container_name: yuvomi
restart: unless-stopped
ports:
# Host-Port aus .env (OIKOS_HTTP_PORT); App im Container bleibt auf 3000.
- "0.0.0.0:${OIKOS_HTTP_PORT:-3000}:3000"
volumes:
- ${DATA_DIR:-./data}:/data
- ${BACKUP_DIR:-./backups}:/backups
# Drop Yuvomi modules into ./modules, or set MODULES_DIR=/path/to/modules in
# .env. The app reads that name inside the container too, so environment:
# below pins it to /app/modules; the .env value only moves the mount source.
- ${MODULES_DIR:-./modules}:/app/modules
# Optional local documents folder. BOTH ends come from the .env: the app
# writes to DOCUMENT_STORAGE_LOCAL_PATH, so mounting at a fixed /documents
# would send uploads into the container layer as soon as anyone changes
# that path - and they would be gone on the next pull && up -d.
- ${DOCUMENT_STORAGE_LOCAL_DIR:-./documents}:${DOCUMENT_STORAGE_LOCAL_PATH:-/documents}
# Bewusst die Kurzform, nicht `path:`/`required:` (Issue #765): die Langform
# gibt es erst ab Compose v2.24, und Synology DSM, QNAP und ältere Distros
# liefern älter - dort scheitert schon das Einlesen mit
# "services.yuvomi.env_file.0 must be a string", also noch vor dem ersten
# Start. Die Langform stand hier für Git-/GitOps-Stacks ohne .env (#698);
# dieser Weg geht seitdem über docs/docker-compose.portainer.yml, das jede
# Variable einzeln aufführt. Sie hier zu behalten kaufte nichts: ohne .env
# fehlt SESSION_SECRET, und der Container beendet sich beim Start - der
# Deploy scheitert also so oder so, nur eine Stufe später.
env_file:
- .env
environment:
- NODE_ENV=production
- DB_PATH=${DB_PATH:-/data/yuvomi.db}
- BACKUP_DIR=/backups
- MODULES_DIR=/app/modules
# Local document storage (optional): set to true to store uploaded documents on the mounted /documents folder.
- DOCUMENT_STORAGE_LOCAL_ENABLED=${DOCUMENT_STORAGE_LOCAL_ENABLED:-false}
- DOCUMENT_STORAGE_LOCAL_PATH=${DOCUMENT_STORAGE_LOCAL_PATH:-/documents}
# Secure cookies come from .env (the installer sets them):
# - Reverse proxy + HTTPS → SESSION_SECURE=true, TRUST_PROXY=1
# - Direct HTTP access → SESSION_SECURE=false, TRUST_PROXY=loopback
# Default when unset (e.g. a .env that does not carry the line): false,
# so direct HTTP login keeps working out of the box.
- SESSION_SECURE=${SESSION_SECURE:-false}
healthcheck:
test: ["CMD", "node", "-e", "require('http').get('http://localhost:3000/health', r => process.exit(r.statusCode === 200 ? 0 : 1))"]
interval: 30s
timeout: 10s
retries: 3
start_period: 10s