Repository navigation
Description
Problem or Motivation
To see the hosts of dan-petty/homelab, a person runs scripts/cluster-status.sh and scripts/health-check.sh, or reads kubectl get nodes and the inventory side by side. On 2026-11-10 the node hawk hung and came back on 2026-11-12 with 16 GiB of RAM; nothing showed the inventory and the node state together. A read of 2026-11-12 shows facts that one view should give: hawk is cordoned, allocatable memory equals capacity on every node (no system reservation yet), and condor runs kernel 7.2.8 while the other nodes run 7.2.15.
Proposed Solution & Architectural Design
devops infra status <repo> (design section 5 in tracker #5120). One row for each inventory host: group, in service or in the offline group, Kubernetes node name (devops_infra_node_name, default the first DNS label), Ready, cordoned, kernel and kubelet version, memory capacity and allocatable, GPU allocatable. All of these come from the Kubernetes API of infra.repos[].kube_context, so the default run starts no SSH connection. --ping adds SSH reachability (ansible-runner ad-hoc ping) and a pending reboot (stat of /run/reboot-required), and needs agent level plan. --format table|json|yaml. --dry-run makes zero requests.
Target Subsystem
OpenTofu / Infrastructure as Code
Existing Tool Considered
The Kubernetes API (through the existing devops k8s client) and ansible-runner give every fact. The command joins them. Cost: about 1.5M tokens to build, 0.2M a quarter to keep, 2 hours.
Acceptance Criteria
- Tests with the fixture repo of feat(infra): onboard an Ansible infra repo #5121 and fake node objects: a cordoned node, a NotReady node, a host in
offlinewith no node, a node with no inventory host. - A test: without
--pingno ansible process starts. - A test:
--pingfrom an agent caller on a repo at levelnoneis refused. - A test:
--dry-runsends no request. - Live run on dan-petty/homelab, recorded in a PR comment: 4 in-service hosts and 2 offline hosts;
hawkcordoned with about 15.5 GiB;--pingreaches the 4 in-service hosts and shows whethercondorhas a pending reboot.
Activity
dan-petty commentedon Nov 12, 2026
Both are part of the devops infra command family; #5120 is the umbrella for all infra repo management, while the candidate is the specific status sub-command.devops-cli-service commentedon Nov 12, 2026
Released in v0.122.0: https://github.com/dan-petty/devops-cli/releases/tag/v0.122.0
devops-cli-service commentedon Nov 12, 2026
Live since 2026-11-12 19:05 UTC