Add host stats to the Proxmox page
The Proxmox page only showed guest (VM/LXC) status; there was no view
of the underlying host(s) themselves -- uptime, CPU/RAM usage, or how
full each storage pool is.
New adapter.listNodeStats() calls GET /nodes/{node}/status and GET
/nodes/{node}/storage for every online node (a node going down
shouldn't blank the whole page, same tolerance as listGuests()) and
returns uptime, CPU usage % + core count + load average, RAM/swap
usage, and per-storage (local, LVM-thin, ZFS, NFS, ...) used/total.
New GET /:id/proxmox/nodes route alongside the existing /guests one.
One card per online node now sits above the VM/LXC table, showing
these stats plus a small storage table with usage bars (reusing the
same green/yellow/red thresholds as the Servers detail page and the
Synology page). Handles a multi-node cluster by rendering one card
per node, and storages with no active/total data (e.g. an offline NFS
mount) render as an "Inactive" badge with blank usage instead of
throwing.
Verified end-to-end against a local mock Proxmox API server over real
TLS (a throwaway self-signed cert, matching how the adapter's
`insecure` option is meant to be used) since this sandbox can't reach
the user's actual Proxmox cluster -- confirmed CPU fraction-to-percent
conversion, load average parsing, byte fields, and that a
null-valued/inactive storage doesn't break parsing.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
1ff59afb40
commit
2d062a9ac4
5 files changed
+260
-5
No files matched your search
@@ -43,8 +43,11 @@ All modules from the original plan are built:
|
||||
- **Tailscale** — device list with online/authorized status, and
|
||||
authorize/deauthorize/remove actions; a live device-count widget.
|
||||
- **Proxmox** — VM/LXC status across every node in the cluster, with
|
||||
start/restart/shutdown/stop actions; a live running/total widget.
|
||||
Supports self-signed certificates (common in homelab setups).
|
||||
start/restart/shutdown/stop actions; a live running/total widget. Each
|
||||
online node also gets its own host-stats card — uptime, CPU usage/cores/
|
||||
load average, RAM and swap usage, and per-storage usage (local, LVM-thin,
|
||||
ZFS, NFS, etc). Supports self-signed certificates (common in homelab
|
||||
setups).
|
||||
- **Synology** — volume and disk health (read-only by design).
|
||||
Supports self-signed certificates.
|
||||
- **Semaphore** — Ansible run status per template across every
|
||||
|
||||
Reference in new issue
Block a user