feat(ha-diag-agent): add piha deploy config

- hosts/piha/runtime/ha-diag-agent/docker-compose.override.yml: mem_limit
  128m, hardcoded events volume (/opt/homelab/events/piha:/events) to avoid
  ${NODE_NAME} shell-expansion issue in deploy-node.sh
- services/ha-diag-agent/env.example: per-host HA_URL comments (piha vs
  chelsty-infra tailscale), HA_TOKEN source note

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Oskar Kapala 2026-06-03 19:19:27 +02:00
parent 58ac6edd7d
commit 6953815f41
2 changed files with 15 additions and 2 deletions

View file

@ -0,0 +1,10 @@
services:
ha-diag-agent:
# Pin events to the piha-specific subdirectory; overrides the ${NODE_NAME}
# variable substitution in the base compose file which requires a shell env var.
volumes:
- /opt/homelab/events/piha:/events
- /var/lib/ha-diag-agent:/data
- /opt/homelab/config/ha-diag-agent:/config:ro
mem_limit: 128m
restart: unless-stopped

View file

@ -2,11 +2,14 @@
# Copy to /opt/homelab/config/ha-diag-agent/.env on the target node
# Home Assistant connection (required)
HA_URL=http://homeassistant.local:8123
# piha: HA_URL=http://localhost:8123
# chelsty-infra: HA_URL=http://100.70.180.90:8123 (chelsty-ha Tailscale IP)
HA_URL=http://localhost:8123
# Obtain from HA UI: Settings → People → <diag_agent user> → Long-Lived Access Tokens
HA_TOKEN=your-long-lived-token-here
HA_TIMEOUT=10.0
# Node identity
# Node identity (must match the node's canonical name in the homelab inventory)
NODE_NAME=piha
LOCATION_TAG=ken