scripts/host-watch.sh: generic tailnet-host SSH watchdog with diag capture on recovery #152
Labels
No labels
burndown-2026-06
burndown-2026-08
autonomy
async-consult
autonomy
epic
autonomy
headless
autonomy
live-collab
coherence-core
priority
P0
priority
P1
priority
P2
priority
P3
priority
P4
qa-fixture
role/advocate
role/director
role/exec
role/frontend
role/gamedev
role/human
role/platform
role/qa
role/science
role/sysadmin
state
ambient
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
coilyco-flight-deck/infrastructure#152
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
Problem
scripts/host-diag.shexists ad-hoc in this session's/tmp/but isn't installed in the repo, isn't reachable viacoily exec, and is hard-coded to one operator's Mac. The watch loop that fires it on dead->alive recovery has the same problem. Promote both into the repo as a single generic verb.Scope
scripts/host-diag.sh- run on the remote host viassh -- bash -s <. Captures listening sockets, sshd state, journals (ssh / k3s / tailscaled), dmesg, conntrack stats, iptables filter + nat, nft ruleset, ufw, fail2ban, interfaces, top RSS, auth.log.scripts/host-watch.sh- pollscoily ssh <alias> -- echo aliveeveryPOLL_INTERVALseconds (default 15). On dead->alive transition, streamshost-diag.shinto the remote and writes the output locally asrecovery-<ts>.txt. State log + snapshots underOUT_DIR(default/tmp/host-watch-<alias>).Makefiletargethost-watchwithhost=<alias>arg..coily/coily.yamlverbhost-watchdelegating to the Make target.Use
Runs interactively until killed (Ctrl-C or
pkill -f host-watch.sh). Originally written to catch the kai-server host-namespace outage during coilysiren/infrastructure#151. Generic enough to point at any tailnet host where coily ssh works.Out of scope