Repository navigation
Commit ae0a921
authored
fix(devenv-image): take devenv 2.4.0 from a pinned nixos-unstable rev (#550)
## Summary
The devenv image now installs devenv 2.4.0 from a pinned
`nixos-unstable` rev (`DEVENV_NIXPKGS_REV`), while direnv stays on the
existing nixos-26.05 pin (`NIXPKGS_REV`). This fixes devenv 2.1.2
ignoring the signing keys of a repo's `cachix.pull` caches, which forces
source builds that sandbox egress blocks. `VERSION` goes to `2.1.0`.
## Eligibility & Accountability
- [x] I am a **federal employee or contractor** (PRs merge with
`@GSA-TTS/agentic-coding-team` code-owner approval; eligibility is
attested here, not authenticated). *Anyone may open issues without
this.*
- [x] **I understand this change and can explain it in my own words** —
I am the author of record and accountable for it.
- [x] By opening this PR, I **attest I have the right to release this
work** under the repository's [CC0-1.0](../LICENSE) dedication.
## AI Assistance Disclosure
- [x] AI tools were used in this contribution
- [x] I verified all AI-generated content: no fabricated/hallucinated
APIs, dependencies, citations, or placeholder content; any AI-suggested
dependency was confirmed to exist.
- [x] Any inherited/reused third-party material retains its original
license and is identified (not represented as public domain).
## Type of Change
- [x] Bug fix
- [x] Infrastructure/tooling change
## Motivation
`devenv-shell:2.0.0` and `devenv-opencode:2.0.0` ship devenv 2.1.2,
which has
[cachix/devenv#3176](cachix/devenv#3176): it
passes an empty `extra-trusted-public-keys`, so Nix ignores every
substitute from `devenv.cachix.org` (the `devenv-nixpkgs/rolling`
default) and other cachix caches. In a sandbox the resulting source
builds fail with `403` from source mirrors that aren't on the egress
allowlist; 3 of 5 login.gov repos failed this way on `2.0.0` and all
build on `1.0.0`.
[cachix/devenv#3178](cachix/devenv#3178) fixed
it in devenv 2.3.1, but `release-26.05` still packages 2.1.2.
## Changes
- `Dockerfile`: new `ARG
DEVENV_NIXPKGS_REV=31ecbaca1bdefa45dffc409f0250bd8039ea0010`, used only
for `#devenv`; direnv keeps `NIXPKGS_REV`. The comment records why, that
both revs are signed by the `cache.nixos.org` key the image already
trusts, and to drop the second pin once the stable branch packages
devenv ≥ 2.3.1.
- `VERSION`: `2.0.0` → `2.1.0` (devenv stays 2.x, so this is a minor
bump under the image contract).
- `README.md`: documents the second pin, advises against `2.0.0`, and
lists `DEVENV_NIXPKGS_REV` among the toolchain changes that need a
`VERSION` bump.
Kits that pin tools to `NIXPKGS_REV` to share the image's closures are
unaffected; only devenv's closure comes from the second rev.
## Testing
- [x] Ran `make validate` locally (all checks pass)
- [ ] Ran `make test` (if applicable)
- [x] Tested with at least one real scenario
- [x] Commit messages follow [Conventional
Commits](https://www.conventionalcommits.org/) format
Acceptance criteria from the issue, checked against a
`workflow_dispatch` build of this branch ([run
40781422183](https://github.com/GSA-TTS/agentic-coding-patterns/actions/runs/40781422183),
which built all four variant/arch images by digest without publishing
tags) and an msb sandbox on the arm64 `devenv-shell` digest:
- [x] `devenv version` in the image reports ≥ 2.3.1 on amd64 and arm64.
arm64: `devenv 2.4.0 (aarch64-linux)` in the sandbox. amd64: the build
log installs `/nix/store/yqm4mhvx…-devenv-2.4.0`; `devenv version`
itself was not run on amd64.
- [x] devenv is substituted from `cache.nixos.org` on both architectures
(no source build in the CI log). All four jobs log `copying path
'…-devenv-2.4.0' from 'https://cache.nixos.org'` and no `building`
lines.
- [x] In a sandbox on the new image, a repo that pulls from
`devenv.cachix.org` builds its shell with no "ignoring substitute"
warnings. identity-idp (which downloads many `devenv.cachix.org` NARs)
and data-transformation (which uses `nixpkgs-python.cachix.org`) both
build; neither of them, nor identity-devops, logs an "ignoring
substitute" warning.
Also verified:
- `pkgs/by-name/de/devenv/package.nix` at `31ecbaca` declares `version =
"2.4.0"`.
- `31ecbaca` was the `nixos-unstable` branch head when this PR was
opened, so it passed the Hydra channel gate.
Known remaining failure, separate from this fix and not a regression:
identity-devops fails on arm64 on both this image and
`devenv-shell:1.0.0` (devenv 1.11.2), at the same `bash53-001` source
fetch. Its lock pins `devenv` and `devenv-nixpkgs` commits from December
2025, and `devenv-tasks-2.0.0` and `python3-3.12.12` for aarch64-linux
at those revs are in none of `cache.nixos.org`, `devenv.cachix.org` or
`nixpkgs-python.cachix.org`. Building them pulls in source fetches from
`ftpmirror.gnu.org`, which egress blocks. The image trusts and
substitutes every path that is cached; a `devenv update` in that repo is
the likely fix.
## Safety Checklist
- [x] No secrets, API keys, tokens, or passwords included
- [x] No PII (names, emails, SSNs, addresses)
- [x] No CUI (Controlled Unclassified Information)
- [x] No internal URLs, hostnames, or system paths
- [x] No customer data or proprietary information
## Validation Results
```
make validate
✓ All validators passed
```
## Related Issues
Closes #549
## Additional Context
Alternatives considered in the issue: backporting devenv ≥ 2.3.1 to
`release-26.05` (fixes it at the source, but the timing is outside this
repo's control; worth requesting in parallel), baking cachix keys into
`nix.conf` (hard-codes keys for caches that individual repos choose),
and kit-side workarounds (fixes one consumer at a time).1 parent 78154ec commit ae0a921
3 files changed
Lines changed: 23 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
12 | 19 | | |
| 20 | + | |
13 | 21 | | |
14 | 22 | | |
15 | 23 | | |
| |||
75 | 83 | | |
76 | 84 | | |
77 | 85 | | |
78 | | - | |
| 86 | + | |
79 | 87 | | |
80 | 88 | | |
81 | 89 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
39 | 44 | | |
40 | 45 | | |
41 | 46 | | |
| |||
90 | 95 | | |
91 | 96 | | |
92 | 97 | | |
93 | | - | |
94 | | - | |
95 | | - | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
96 | 101 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
0 commit comments