Host Health
@aaronge/host-healthv2026.11.05.2
01README
Zero-privilege Linux host telemetry (disk, thermal, load, memory) as a typed, versioned Swamp model for workflow assertions and CEL joins.
02Release Notes
Documentation, descriptions and setup brought up to date with running every workflow under a single swamp serve (2026-11-05).
03Behaviors
@aaronge/host-healthv2026.08.26.3host_health.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| diskWarnPercent? | number | Root filesystem usedPercent threshold that trips an assert step. Not consumed by any method directly — read by the host-health workflow's assert job. |
| tempWarnCelsius? | number | Thermal zone maxCelsius threshold that trips an assert step. Matches the Pi 5 soft limit; sensible on most hosts. Not consumed by any method directly. |
| loadWarnPerCore? | number | 5-minute load average divided by core count that trips an assert step. Not consumed by any method directly. |
| memWarnPercent? | number | Memory usedPercent (based on MemAvailable, not MemFree) that trips an assert step. Not consumed by any method directly. |
| includeVirtualFs? | boolean | Whether readFilesystems includes tmpfs/devtmpfs/other virtual mounts in the filesystems.mounts array. |
fn readFilesystems()
Run `df -P -B1`, classify each mount as virtual or real via /proc/mounts fstype, and write the filesystems resource.
fn readThermal()
Read every thermal zone under /sys/class/thermal, sanity-checked to -50..150C, and write the thermal resource.
fn readLoad()
Read /proc/loadavg and core count from /proc/cpuinfo, and write the load resource.
fn readMemory()
Read /proc/meminfo, using MemAvailable (not MemFree) for usedPercent, and write the memory resource.
Resources
filesystems(infinite)— Per-mount disk usage, with root and worst-case usedPercent hoisted for CEL asserts.
thermal(infinite)— Per-zone temperature readings from /sys/class/thermal.
load(infinite)— System load averages and process counts from /proc/loadavg.
memory(infinite)— Memory and swap usage from /proc/meminfo, based on MemAvailable.
04Workflows
@aaronge/host-health73546362-7553-4093-a058-7ead3d99cccf
Collect disk, thermal, load, and memory telemetry from host-local, assert each against a threshold, and print a one-screen summary. Fails when any threshold is breached.
collectRead filesystem, thermal, load, and memory state in parallel.
1.readFilesystemshost-local.readFilesystems
2.readThermalhost-local.readThermal
3.readLoadhost-local.readLoad
4.readMemoryhost-local.readMemory
assertFail the run when any threshold is breached.
1.disk-ok
2.thermal-ok
3.memory-ok
4.load-ok
reportPrint a one-screen summary. Depends on collect only (not assert), so it still runs when an assertion fails.
1.summarize
05Previous Versions
2026.11.05.1
Ship the workflow in the package so a single ops repo can pull it and run it under swamp serve's own scheduler.
Added 1 workflows
2026.08.26.3
2026.08.26.2
2026.08.26.1
06Stats
A
93 / 100
Downloads
44
Archive size
15.4 KB
- Has README or module doc2/2earned
- README has a code example1/1earned
- README is substantive1/1earned
- Most symbols documented1/1earned
- No slow types (deprecated)1/1earned
- Dependencies pass trust audit2/2earned
- Docs keep secrets in a vault1/1earned
- Has description1/1earned
- Platform support declared (or universal)2/2earned
- License1/2partial
no SPDX license declared
- Verified public repository2/2earned
07Platforms