Derive profile checks from inventory-supported platforms #2
Labels
No labels
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
allod/profiles#2
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?
So that profile definitions stay portable across supported machines, profile checks should use the shared inventory platform list instead of carrying their own architecture list.
Context
Machine platform facts have one owner:
allod/inventory. The profiles flake currently duplicates supported platform keys in its own localcheckSystemslist, then generateschecksfrom that duplicate list. That can drift from inventory as supported machines are added, removed, or renamed, and it makes architecture policy harder to enforce consistently across public repos.Exact grep hits
Scope
inventoryflake input for the profiles repo.checkSystemslist withinventory.lib.supportedPlatforms.Acceptance
flake.nixno longer defines a local machine platform list such ascheckSystems = [ "x86_64-linux" ... ];.checksare generated frominventory.lib.supportedPlatforms.Closing in favor of #3, which carries the corrected mechanism.
This issue's goal — don't let a hardcoded architecture list drift from inventory — is sound, but its prescribed fix (add an
inventoryinput and derivecheckSystemsfrominventory.lib.supportedPlatforms) is wrong here. ThecheckSystemslist atflake.nix:21is not machine-platform policy: the check it keys (flake.nix:88-99) is a platform-independent shape validation, so it can never drift from inventory, and adding an inventory input would break this repo's deliberate definitions-only, no-inventory/no-secretscharter (flake.nix:8) to fix a non-problem. The inventory-single-owner principle the issue wants already lives one layer up, inallod/archetypes(flake.nix:48), where real machine checks are generated.#3 replaces the mechanism: de-literalize the check keying via
nixpkgs.lib.systems.flakeExposed(no new input) and hoist the shape asserts ontolib.profileDefinitionsso the framework trips them at composition time — closing a gap where this check currently protects only standalone runs, not consumers. Closing as not planned; see #3.Closed as not planned.