services: dashboard: build: context: . dockerfile: Dockerfile image: homelab-dashboard:latest container_name: homelab-dashboard ports: - "8888:80" restart: unless-stopped environment: # Timezone used for the "Today" calendar widget. - TZ=Europe/Vienna # Secrets live in .env (gitignored) — compose reads it automatically. - OPENWEBUI_TOKEN=${OPENWEBUI_TOKEN:-} - GITEA_TOKEN=${GITEA_TOKEN:-} # Outlook unread-mail widget (see README for the Entra ID app registration # and the one-time device login). - OUTLOOK_CLIENT_ID=${OUTLOOK_CLIENT_ID:-} - OUTLOOK_TENANT=${OUTLOOK_TENANT:-organizations} # Optional API tokens for live stats / git integration. # Uncomment and fill in to enable private git stats. # - GITLAB_TOKEN= # - NETBIRD_TOKEN= # Forward proxy for GitLab API access + health checks (api/proxy.js). # Set the URL in .env — change it there when the proxy stack moves # (unset = direct connection). With the proxy on the docker host: # GITLAB_PROXY=http://host.docker.internal:8118 - GITLAB_PROXY=${GITLAB_PROXY:-} # GPU stats upstream; defaults to the gpu-stats service below. # To run gpu_stats.py on the host instead, use: # http://host.docker.internal:9101/stats # (and add: extra_hosts: ["host.docker.internal:host-gateway"]) # - GPU_STATS_URL=http://gpu-stats:9101/stats # Ollama instance for the loaded-model stats in the GPU widget. # - OLLAMA_URL=http://100.103.83.12:11435 extra_hosts: # Alias for the docker host, so container services can reach host # processes (e.g. the proxy behind GITLAB_PROXY) by a stable name. - "host.docker.internal:host-gateway" volumes: # Persists the Outlook OAuth refresh token across container updates. - outlook-tokens:/opt/dashboard/tokens logging: driver: json-file options: max-size: "1m" max-file: "2" # AMD GPU stats via rocm-smi (gpu_stats.py). # Needs the host's ROCm install + GPU device nodes passed through. gpu-stats: image: python:3.12-slim container_name: homelab-gpu-stats restart: unless-stopped environment: # rocm-smi can't read the device name without libdrm; set it explicitly. - GPU_NAME=AMD Radeon AI PRO R9700 # - ROCM_SMI_PATH=/opt/rocm/bin/rocm-smi volumes: - ./gpu_stats.py:/app/gpu_stats.py:ro - /opt/rocm:/opt/rocm:ro devices: - /dev/kfd - /dev/dri command: python3 /app/gpu_stats.py logging: driver: json-file options: max-size: "1m" max-file: "2" volumes: outlook-tokens: