services: guardian: image: guardian:latest build: context: . dockerfile: Dockerfile container_name: guardian restart: unless-stopped # Use host network mode to measure real host network interfaces (20+ MB/s download/upload stats) # network_mode: host ports: - "3001:3001" volumes: # Docker Daemon socket (auto-discovery, stats, container restart, host power controls) - /var/run/docker.sock:/var/run/docker.sock # Host telemetry (procfs for CPU, RAM, and top processes breakdown) - /proc:/host/proc:ro - /sys:/host/sys:ro # Host identification (real distro name and hostname for confirmations) - /etc/os-release:/host/etc/os-release:ro - /etc/hostname:/host/etc/hostname:ro # Storage monitoring — mount whatever you want measured - /:/host/root:ro - /mnt/nas:/host/mnt/nas:ro # Persistent icons, bookmarks, and settings config - guardian_data:/data environment: - HOST_PROC=/host/proc - HOST_SYS=/host/sys - HOST_ETC=/host/etc - HOST_ROOT=/host/root - HOST_NAS=/host/mnt/nas # Optional: extra mount points to watch, comma separated # - HOST_MOUNTS=/host/mnt/backup # Seed the LAN / Tailscale launch targets; both editable in Settings - SERVER_IP=192.168.1.100 - TAILSCALE_IP=100.x.y.z - PORT=3001 - NODE_ENV=production # Shutdown / reboot from the dashboard. Set to true to enable Power controls in the header. # When running with Docker socket mounted, Guardian cleanly executes host power actions. - ENABLE_POWER_CONTROLS=true # Optional custom power command (e.g. ssh, nsenter) # - GUARDIAN_POWER_COMMAND=/usr/bin/ssh admin@host sudo systemctl {action} deploy: resources: limits: memory: 128M cpus: '0.50' volumes: guardian_data: name: guardian_data