Repository navigation
feat: publish Kubernetes metadata bundles with each staged release - #13566
Merged
cv merged 2 commits intoOct 21, 2026
Merged
Conversation
cv
added a commit
that referenced
this pull request
Oct 23, 2026
## Narrowed by maintainers This PR now keeps SBOMs as private draft assets and leaves attestation to final releases: - Staging generates one SPDX 2.3 document per platform digest with pinned Syft (a short shell loop) and attaches them to the draft with `sboms.json`, plus an SBOM table in the release notes. - The `release-sboms` command and its Rust checks are removed: Syft scans the exact reference it is given and writes SPDX itself, and the staging workflow already enforces the release's images and platforms. - The `v1-release-attestations` approval environment and the attest jobs are removed. Release candidates and internal packages publish nothing about their images; final releases will attest SBOMs together with provenance, recorded in #13521. - Kept: retaining `Cargo.lock` in the supervisor and proxy images. Validation: `cargo ci`, `docker buildx bake check`, `actionlint` and `fern check` pass. A proxy image built from this branch carries `/usr/share/doc/nemoclaw-ollama-proxy/Cargo.lock`, and the workflow's Syft command finds 79 packages in it, including hyper, serde and tokio. The author's original description follows. --- ## Outcome The v1 release workflow generates an SPDX package inventory for every Linux ARM64 and AMD64 image and keeps each inventory as a draft-release asset. After explicit approval to disclose the inventories, separate jobs attach and verify SBOM attestations against the same platform digests without rebuilding the images. ## Reason Released images currently have no package inventory for users to inspect or for the vulnerability-scanning follow-up to consume. This builds on the checked-image publishing in #13533, release staging in #13534, and Kubernetes metadata assets in #13566. ### Related issues Refs #13522. Part of #13516. Provenance (#13521), vulnerability policy (#13523), and license review (#13524) remain separate. ## Changes - Derive platform coverage from the indexes staged by the existing release inventory, including reused agent and proxy images. Pinned Syft generates SPDX JSON from immutable platform references. The Rust integration checks the scanner's source digest and platform, rejects incomplete or invalid evidence, and exposes assets only after every scan succeeds. Fixture tests cover substitution, missing platforms, scanner failures, oversized documents, and reruns; a CLI test checks the saved asset mapping and checksums. - Keep digest-named SPDX assets and `sboms.json` beside the existing metadata bundles, and list their mappings in the release notes. Retain the supervisor and proxy package lockfiles in their images so Syft can catalog Rust dependencies without relying on stripped binary metadata. - Require the `v1-release-attestations` environment's approval before jobs with OIDC, attestation-write, or registry-write credentials can issue public evidence. The approval check refuses an environment without required reviewers; its shell policy is exercised against protected and unprotected fixtures. The workflow checks the downloaded asset checksum before pinned `actions/attest` attaches the SPDX predicate through OCI referrers. Document verification and partial-failure recovery. ## Verification - `NEXTEST_TEST_THREADS=4 cargo ci` passed formatting, Clippy, the workspace build, 1,556 tests, doctests, schema checks, native bundle construction, and 151 lifecycle tests. The first run hit cache contention in an unchanged dependency test; the rerun passed without changing test budgets. - `cargo test --locked -p nemoclaw-build --no-default-features --test integration release_sboms::` passed all six tests on the final fixtures. `cargo fmt --all -- --check` and focused Clippy with `-D warnings` also passed. - `actionlint .github/workflows/release.yml` passed with actionlint 1.7.12. Fern validation passed on the final documentation with Node.js 24.22.0, reporting zero errors and one warning per version. - `AGENT_PLATFORM=linux/arm64 docker buildx bake --check ollama-proxy` passed without warnings. Cargo packaging generated the proxy-specific lockfile, and pinned Syft catalogued 79 packages from it, including Hyper, Serde, and Tokio. This checks metadata discovery, not complete image contents. Live Docker qualification was not run because the local Colima context does not provide the harness's required Docker socket. Runtime recipe checks could not evaluate Bake target contexts with this builder. Actual OS, Python, Node, and Rust coverage in the released images, protected approval, attestation verification (including a mismatched digest), unchanged registry digests, and internal package visibility remain unverified until a separately authorized release validation run. The diff contains no secrets, API keys, or credentials. ## Review notes Decision: use SPDX JSON with pinned Syft and `actions/attest`'s `sbom-path`, and keep staging assets private until protected approval authorizes public attestation metadata. Reason: users and #13523 need inventories bound to exact image manifests. Attestations from a public repository use public Sigstore infrastructure even when registry packages are internal. Placement: the release workflow owns generation, draft assets, and approved attachment; the Rust build tool owns complete platform coverage and scanner-result binding. Upstream tools own package discovery, SPDX serialization, and attestation generation. Validation plan: use fixture and CLI tests for release coverage, denial, and recovery; verify real image contents, environment approval, OCI referrers, digest preservation, and registry visibility in a separately authorized release run. Before that run, an administrator must configure required reviewers and release-tag restrictions on `v1-release-attestations`. The initiating maintainer accepted this boundary for the change. Self-review of `deepujain/NemoClaw@64b8aa7` covered `.github/workflows/release.yml`, the SBOM integration, and the image metadata recipes. The release workflow is a sensitive path. Review covered input validation, credential scope, approval ordering, digest binding, and partial failures. No independent approval is claimed; independent review and hosted CI remain required. Rust lockfile entries include retained build dependencies and do not claim that every dependency is linked into the executable. --- Signed-off-by: Deepak Jain <[email protected]> --------- Signed-off-by: Deepak Jain <[email protected]> Signed-off-by: Carlos Villela <[email protected]> Co-authored-by: Carlos Villela <[email protected]>
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.
Closes #13548. Stacked on #13565.
Failure
A Kubernetes sandbox names its agent image's metadata bundle in
image.metadata, but a bundle could only come fromcargo images export-metadatarun on a locally built image. A user deploying a published release had no way to get one: the tool isn't in the CLI, anddocker image saveof a pulled multi-platform image omits the configs it needs. Found while testingv1.0.0-rc1(#13516).Decision
Publish the bundles with each release, instead of making the CLI read registries (that would mean NemoClaw handling registry logins, which belongs to Docker and the registry).
cargo images export-metadata --registry HOST/REPOSITORY@sha256:DIGESTfetches the root and, for each Linux platform it lists, the platform's manifest and config over the registry API. It checks every document against its digest, skips attestations, and builds the bundle with the same code as a local export, so both produce identical bundles. It answers the registry's bearer-token challenge, withNEMOCLAW_REGISTRY_USERNAMEandNEMOCLAW_REGISTRY_PASSWORDwhen set. Plain HTTP is allowed only for loopback hosts.ghcr.iowith the workflow's token. It attaches the bundles to the draft as<image>.metadata.jsonand adds a Kubernetes metadata column to the release notes. The runtime and proxy images don't need one.docs/kubernetes.md: for a published release, use the index reference from the notes and the attached bundle;docs/build.md:--registry;docs/contributing/releases.md: the attached bundles.Validation
ghcr.io, exportingv0.1.0-rc1'sv1/deepagentsindex with a token wrote a schema 2 bundle with the index, the arm64 and amd64 manifests, and both configs.actionlintis clean,cargo cipassed, andfern checkreported 0 errors.v0.1.0-rc2and deploying its Deep Agents image on kind straight from the release's index and bundle is the end-to-end check for Provide Kubernetes metadata bundles for published agent images #13548's "done when".