Docker Compose an aktuellen Code-Stand angepasst
This commit is contained in:
@@ -2,48 +2,21 @@ services:
|
|||||||
watcher:
|
watcher:
|
||||||
image: git.triggermeelmo.com/triggermeelmo/watcher-server:latest
|
image: git.triggermeelmo.com/triggermeelmo/watcher-server:latest
|
||||||
container_name: watcher
|
container_name: watcher
|
||||||
|
|
||||||
# Resource Management
|
|
||||||
deploy:
|
deploy:
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
memory: 200M
|
memory: 200M
|
||||||
|
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
user: "1000:1000"
|
||||||
# Security - User/Group ID aus Umgebungsvariablen
|
|
||||||
user: "${USER_UID:-1000}:${USER_GID:-1000}"
|
|
||||||
|
|
||||||
# Health Check
|
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "curl", "-f", "http://localhost:5000/health"]
|
test: ["CMD", "curl", "-f", "http://localhost:5000/health"]
|
||||||
interval: 30s
|
interval: 30s
|
||||||
timeout: 10s
|
timeout: 10s
|
||||||
retries: 3
|
retries: 3
|
||||||
start_period: 40s
|
start_period: 40s
|
||||||
|
|
||||||
# Environment
|
|
||||||
environment:
|
environment:
|
||||||
# Non-Root User
|
|
||||||
- USER_UID=1000 # Standard 1000
|
|
||||||
- USER_GID=1000 # Standard 1000
|
|
||||||
|
|
||||||
# Timezone
|
|
||||||
- TZ=Europe/Berlin
|
|
||||||
|
|
||||||
# Update Check
|
|
||||||
- UPDATE_CHECK_ENABLED=true
|
|
||||||
- UPDATE_CHECK_INTERVAL_HOURS=24
|
|
||||||
- UPDATE_CHECK_REPOSITORY_URL=https://git.triggermeelmo.com/api/v1/repos/Watcher/watcher/releases/latest
|
|
||||||
|
|
||||||
# Data Retention Policy
|
|
||||||
- METRIC_RETENTION_DAYS=30
|
|
||||||
- METRIC_CLEANUP_INTERVAL_HOURS=24
|
|
||||||
- METRIC_CLEANUP_ENABLED=true
|
|
||||||
|
|
||||||
# Aktualisierungsrate Frontend
|
# Aktualisierungsrate Frontend
|
||||||
- FRONTEND_REFRESH_INTERVAL_SECONDS=30
|
- FRONTEND_REFRESH_INTERVAL_SECONDS=30
|
||||||
|
|
||||||
# OIDC-Authentifizierung (Optional)
|
# OIDC-Authentifizierung (Optional)
|
||||||
# - OIDC_ENABLED=true
|
# - OIDC_ENABLED=true
|
||||||
# - OIDC_AUTHORITY=https://auth.example.com/realms/myrealm
|
# - OIDC_AUTHORITY=https://auth.example.com/realms/myrealm
|
||||||
@@ -54,23 +27,19 @@ services:
|
|||||||
# - OIDC_CLAIM_USERNAME=preferred_username
|
# - OIDC_CLAIM_USERNAME=preferred_username
|
||||||
# - OIDC_CLAIM_EMAIL=email
|
# - OIDC_CLAIM_EMAIL=email
|
||||||
# - OIDC_AUTO_PROVISION_USERS=true
|
# - OIDC_AUTO_PROVISION_USERS=true
|
||||||
|
|
||||||
# Ports
|
|
||||||
ports:
|
ports:
|
||||||
- "5000:5000"
|
- "5000:5000"
|
||||||
|
|
||||||
# Volumes
|
|
||||||
volumes:
|
volumes:
|
||||||
- ./data/db:/app/persistence
|
- ./data/db:/app/persistence
|
||||||
- ./data/dumps:/app/wwwroot/downloads/sqlite
|
- ./data/dumps:/app/wwwroot/downloads/sqlite
|
||||||
- ./data/logs:/app/logs
|
- ./data/logs:/app/logs
|
||||||
|
|
||||||
# Labels (Traefik Integration)
|
|
||||||
labels:
|
labels:
|
||||||
|
# Traefik konfiguration
|
||||||
- "traefik.enable=true"
|
- "traefik.enable=true"
|
||||||
- "traefik.http.routers.watcher.rule=Host(`watcher.example.com`)"
|
- "traefik.http.routers.watcher.rule=Host(`watcher.example.com`)"
|
||||||
- "traefik.http.routers.watcher.entrypoints=websecure"
|
- "traefik.http.routers.watcher.entrypoints=websecure"
|
||||||
- "traefik.http.routers.watcher.tls.certresolver=letsencrypt"
|
- "traefik.http.routers.watcher.tls.certresolver=letsencrypt"
|
||||||
- "traefik.http.services.watcher.loadbalancer.server.port=5000"
|
- "traefik.http.services.watcher.loadbalancer.server.port=5000"
|
||||||
|
# Labels, die von watcher-agent verwendet werden
|
||||||
- "com.watcher.description=Server Monitoring Application"
|
- "com.watcher.description=Server Monitoring Application"
|
||||||
- "com.watcher.version=${IMAGE_VERSION:-latest}"
|
- "com.watcher.version=${IMAGE_VERSION:-latest}"
|
||||||
|
|||||||
Reference in New Issue
Block a user