Document NixOS as a supported OS for the Smallstep Agent - #540
Open
joshdrake wants to merge 2 commits into
Open
Conversation
NixOS is now a supported OS for the agent, but the nixpkgs package ships only the binary. Everything the .deb/.rpm postinst does -- system user, systemd unit, tmpfiles, polkit, tss group, p11-kit module registration -- has to be declared by hand, because nixpkgs has no services.step-agent module yet (OFF-2). Add NixOS to the supported-OS list and a NixOS section under Manual install carrying the equivalent configuration, ported field-for-field from agent/extra/. Also note the NixOS deltas in Start the agent, the Chrome PKCS#11 example, Uninstall, and the troubleshooting reference. Two limitations stated plainly: the package is on nixos-unstable only (it missed the 26.05 branch-off), and hosts without a hardware TPM cannot enroll, since the swtpm helper scripts are not packaged. The Nix config was verified to evaluate against nixos-unstable and to render a step-agent.service matching agent/extra/step-agent.service. It has not been runtime-tested on a NixOS host. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KSuffpV7e9tawW249FA7gN
The search.nixos.org link pinned channel=20.09, which has been unsupported for years, so the page showed no results. Without the param it resolves against the current channel, matching how the step-ca installation page already links NixOS packages. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KSuffpV7e9tawW249FA7gN
|
|
joshdrake
marked this pull request as ready for review
July 27, 2026 17:52
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.
Describe your changes:
Closes OFF-13.
The
step-agentpackage was upstreamed to nixpkgs, but it ships only the binary. Everythingagent/extra/step-agent.postinstdoes on Debian and RPM — system user, systemd unit, tmpfiles, polkit rules,tssgroup, p11-kit module registration — has no equivalent on NixOS, because there is noservices.step-agentmodule yet (OFF-2). So a NixOS admin currently has no path from "install the package" to "enrolled device".platform/smallstep-agent.mdxNixOSadded to the supported-OS list under System requirements → Linux.agent/extra/— plus an unstable overlay for stable-channel users and theregisterstep.platform/troubleshooting-agent.mdx— the two genuine NixOS deltas in the Linux platform reference (no/usr/bin/step-agent;doctorreports p11-kit missing without an explicit store path).step-cli/installation.mdx— separate commit dropping achannel=20.09pin from the NixOS search link, which had gone dead.Two limitations are stated plainly in the docs rather than papered over:
nixos-unstableonly — it merged after the 26.05 branch-off, so the first stable NixOS release carrying it is 26.11.swtpm-setup/swtpm-certcreatehelpers the.debships are not part of the nixpkgs package, and the EK cert they mint identifies the software TPM to the attestation CA, so it is not something an operator can hand-roll from the docs.Verified
pkgs.step-agentbuilds fromnixos-unstableand./result/bin/step-agent versionruns — the documented version output is its real output.configuration.nixsnippet evaluates throughnixosSystem, and the renderedstep-agent.servicematchesagent/extra/step-agent.servicedirective for directive.pkgs.step-agenton a stable channel with no eval warnings.${pkgs.p11-kit}/lib/pkcs11/p11-kit-client.soexists, and NixOS's p11-kit does read/etc/pkcs11/modules(confirmed against the compiled-in config path), so theenvironment.etcregistration takes effect.tssmust be a system group) is closed, so no workaround is documented.markdown-link-checkare clean — Vale output is byte-identical to the pre-change baseline (the 5 pre-existingGoogle.EmDasherrors are untouched).Not verified: none of this proves the agent actually enrolls end to end on a real NixOS host with a hardware TPM. That needs a NixOS machine or the VM test from OFF-4. Worth having Diego or Kylian at BSI run the recipe before this merges, since they have NixOS fleets in production.
Related links/other PRs/issues:
Gaps found during this work, filed as follow-ups: OFF-14 (stable-channel backport), OFF-15 (release-process version bump), OFF-16 (package metadata). Existing coverage: OFF-2 (module), OFF-3 (declarative enrollment), OFF-4 (VM test), OFF-5 (PKCS#11), OFF-6 (derivation hardening), OFF-8 (license sign-off).
🤖 Generated with Claude Code
https://claude.ai/code/session_01KSuffpV7e9tawW249FA7gN