feat(monitoring): Rosenpass unit-state + PSK-rotation alerts for Link A #84
Loading…
Reference in a new issue
No description provided.
Delete branch "wt/t_20e420af"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Makes a dead or wedged Rosenpass on Link A (rpi
wg010.10.0.1 ↔ siriussecwg010.10.0.2) visible. Today the exchange can stop and nothing notices: WireGuard keeps using the last preshared key, so the tunnel stays up and silently stops being post-quantum.What
infrastructure/networking/rosenpass/(host config, not Flux-reconciled)rosenpass-metrics.sh— POSIXsh, run byrosenpass-metrics.timerevery 60 s as root on rpi and siriussec only. Writes/var/lib/node-exporter/textfile/rosenpass.promatomically (tmp+mv) with:rosenpass_unit_active{node="<host>"}rosenpass_psk_rotation_age_seconds{node,interface="wg0"}rosenpass_psk_rotation_last_change_timestamp_seconds{node,interface="wg0"}The
wg show wg0 preshared-keysoutput is piped straight intosha256sum; only the digest + last-change timestamp are stored (/var/lib/rosenpass-exporter/last-hash, root-only). No key material is printed, logged or persisted.rosenpass-metrics.service/.timerwithProtectSystem=strict,StateDirectory=; deliberately noRequires=/After=onrosenpass.service— the recorder must keep reporting while the unit it watches is dead.monitoring/controllers/home/values.yaml— insideprometheus-node-exporter::--collector.textfile.directory=/host/textfile, hostPath/var/lib/node-exporter/textfile(DirectoryOrCreate, so linode keeps starting), read-only mount. The chart's image is distroless with no textfile collector and--collector.systemdneeds dbus, hence the host script.monitoring/controllers/home/rosenpass.yaml—PrometheusRulelabelledrelease: kube-prometheus-stack:RosenpassDown:max by (node) (rosenpass_unit_active) == 0for 5 m, warningRosenpassPskRotationStalled:max by (node, interface) (rosenpass_psk_rotation_age_seconds) > 900for 10 m, warningabsent()arms naming rpi/siriussec, so a missing series (timer off, script broken, scrape gone) alerts instead of reading as healthy — and linode, which has node-exporter but no rosenpass, does not page.Verification done on this branch (pre-merge)
kubectl kustomize monitoring/controllers/home→ exit 0, 5 PrometheusRules in the output includingrosenpass.promtool check ruleson the renderedspec.groups(in-cluster pod, prometheus v3.15.1 image) →SUCCESS: 2 rules found.helm templateof the pinned chart (kube-prometheus-stack 92.14.0 / node-exporter 4.60.1) shows the three args (textfile dir + the two default filesystem excludes, re-stated because Helm replaces lists, not merges) plus the textfile volume/mount.active (waiting),.promfile contains all three series withrosenpass_unit_active 1and a fresh timestamp.Not verifiable until this merges
Series present in Prometheus, either alert actually firing, and Alertmanager → Telegram delivery. Flux only reconciles
master, so nothing here is live yet.Out of scope: Link B / Linode / Phase C, any change to rosenpass itself, Grafana dashboard.