Add the machine-coverage check to the framework so every deployment's gate runs it #149
No reviewers
Labels
No labels
blocked
bug
decision
duplicate
enhancement
help wanted
invalid
landed?
question
ready-to-merge
stale
wontfix
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
allod/archetypes!149
Loading…
Reference in a new issue
No description provided.
Delete branch "agent/machine-coverage-framework"
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?
Nothing changes on any running machine. The framework gains one check,
machine-coverage, that every deployment's gate now runs against that deployment's own data: its inventory machines, its host-key table and its four identity sets must name one set of machines, each identity under its machine type's set. The same check landed last week in the secrets template (allod/secrets#48), where it protected only the template, since every deployment builds from a private fork of that repo and pins this one; a second pull request removes that copy. What stays identical: every machine derivation, every other check, the existing identity assertion inmachineConfigurationsand the host-key guard invm-facts.nix. Proof: the gate on this branch is green with the new check built; the check is green against the fork fixture with all three data inputs overridden, so it names nothing from the template; four sabotaged copies of the template's data are each refused by name; and a rule disabled inside the check turns its own fixture assertion red. If it is wrong, revert the one commit; a deployment whose legal layout it refuses sees which name and which file, and the fix is a data edit.Refs allod/archetypes#148
Risk
R1. One new check;
flake.nixpasses four more values into the check index and nothing else moves. The worst credible failure after validation is a fork with a layout the fixtures did not anticipate going red on its next archetypes bump, with a message naming the offender. Rollback is a revert.Validation
allod check .on the branch:All 47 steps passed (checks: 31 built),machine-coveragebuilt.nix build .#checks.x86_64-linux.machine-coveragewithsecrets,profilesandinventoryoverridden tochecks/fork-fixture/(thepath:formfork-safety.shuses): green. The fixture's secrets export noserviceIdentities, and the existingor {}default carries it.--override-input secrets: a guest deleted frommachine-host-keys.jsonwith its ciphertext; an entry for a machine the inventory never declares; a guest removed fromidentity.nix; a service machine moved underprivacyVMs. Each refused with its own message naming the offender.guestsWithoutHostKeyforced empty): the fixture assertion fails, so the fixtures are load-bearing. Restored, the output path matches the healthy run.machineHostKeys(a secrets input predating the export) is refused with the messagevm-facts.nixalready uses, covered by its own fixture.fork-safety.sh, which is a lock-bump-path witness and peaks near this box's memory ceiling; the single-check form above is its mechanism applied to the one check this change adds.