feat(nix): package the gates as a reproducible flake (runtime-bundled bins)#13
Merged
Conversation
…, runtime-bundled bins) A third consumption model alongside vendoring + npm: a nix flake exposing every ck-* gate/generator as a hermetic, pinned CLI — fitting the bounded-systems nix-everything ecosystem (tezcatl-flake et al.) and the kit's reproducibility ethos. The win beyond consistency: each bin bundles the runtime it shells out to, so it is self-contained (the way tezcatl-flake bundles WebKit): • ck-html-validator-gate carries a JRE (vnu is a Java jar) • ck-vuln-gate carries npm (for `npm audit`) — verified each runs with NO java/node on $PATH. The other gates are pure Node + their bundled node_modules. (ck-axe-gate still needs a browser via $AXE_RUNNER.) nix run github:bounded-systems/conformance-kit#ck-axe-gate -- dist flake.nix (buildNpmPackage, npmDepsHash pinned, dontNpmBuild) + flake.lock; README documents the third model. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
"Shouldn't we use flakes for bins?" — yes. A third consumption model alongside vendoring + npm: a nix flake exposing every
ck-*gate/generator as a hermetic, pinned CLI. Fits the bounded-systems nix-everything ecosystem (tezcatl-flake et al.) and the kit's reproducibility ethos.The win beyond consistency
Each bin bundles the runtime it shells out to, so it's self-contained — the way
tezcatl-flakebundles WebKit:ck-html-validator-gatecarries a JRE (vnu is a Java jar)ck-vuln-gatecarries npm (fornpm audit)Verified each runs with no java/node on
$PATH. The other gates are pure Node + their bundlednode_modules. (ck-axe-gatestill needs a browser via$AXE_RUNNER: tezcatl / Playwright.)What
flake.nix—buildNpmPackage(npmDepsHash pinned,dontNpmBuild), per-binapps, JRE/npm wraps.flake.lock; README documents the third model.Verification (local)
nix buildsucceeds;ck-vuln-gate/ck-html-validator-gate/ck-baseline-gateall run from the store with no runtime on$PATH;nix run .#ck-baseline-gatefails closed correctly. (npm teststill 17/0.)Maintenance note
npmDepsHashis pinned — whenpackage-lock.jsonchanges, recompute vianix run nixpkgs#prefetch-npm-deps -- package-lock.json. Anix flake checkCI job would catch drift (follow-up).🤖 Generated with Claude Code