Centralize netdata monitoring on nuc-mini
Created by: jedmund
Summary
- New
monitoringrole installs netdata on every host and configures parent/child streaming so all metrics aggregate to nuc-mini with 30-day retention. - Adds
https://netdata.atelier.house(TinyAuth-protected dashboard) andhttps://netdata.atelier.house/api/*(no-auth bypass) so the LINE dashboard backend can pull metrics for widgets. - Discovers and fixes a long-standing ddclient bug: the compose mount path didn't match what linuxserver/ddclient actually reads, so DNS records have only been working because they were added in Cloudflare manually.
Topology
- Parent (nuc-mini) receives streamed metrics from children, dbengine retention configured for ~30 days at minute resolution via tier 1.
- Children (max, rack-mini) stream to nuc-mini and keep ~1 day of local retention to buffer through parent outages.
- All three nodes appear in
http://nuc-mini:19999/api/v2/nodesonce running.
Notes
- Streaming API key lives in
vault_netdata_stream_api_keyin thecompute_serversvault. Generate withuuidgenif you don't have one set. - The Linux handler uses
systemctl restart --no-block+wait_forbecause netdata's dbengine reconfig takes longer than systemd's D-Bus method timeout, which would otherwise fail every restart even when netdata succeeds. - For the macOS host (rack-mini), brew-installed netdata needs System Settings → Privacy & Security → Local Network permission turned on. Without it, the daemon fails LAN connections silently with
errno 65 No route to hosteven thoughnc/curlwork fine. Can't be automated. - ddclient's
cloudflareprotocol only updates existing A records. Thenetdata.atelier.houseA record needs to be created once in Cloudflare before ddclient picks it up.
Test plan
-
make deploy-prerequisites— installs netdata on all three hosts, configures streaming -
curl -s http://nuc-mini:19999/api/v2/nodesreturns nuc-mini, atelier-max, rack-mini -
make deploy-infra-gateway— applies new Traefik routes and ddclient mount fix -
ddclient actively pushing updates to Cloudflare (verified in container logs) -
After Cloudflare A record is created: https://netdata.atelier.houseredirects to TinyAuth,https://netdata.atelier.house/api/v2/nodesreturns the unauthenticated node list