feat: publish images to ghcr.io/midnightntwrk with signing and SBOM#645
Merged
Conversation
added 9 commits
February 10, 2026 14:27
Use docker buildx imagetools create for server-side manifest copy instead of pull/tag/push. Add cosign signing and signature verification steps for both midnight-node and midnight-node-toolkit.
cosign verify IMAGE:TAG resolves the tag to the manifest list index digest and looks for a signature there. Previously we only signed per-platform digests, causing verification by tag to fail with "no signatures found". Now sign_with_retry also signs the manifest list index itself for multi-arch manifests, so both tag-based and digest-based verification work.
- Sign manifest list by digest instead of tag (cosign v3 deprecates tag references and this avoids potential race conditions) - Add 10s delay between signing and verification to allow signature propagation in the registry - Improve verify step output with per-image labels
Add arch-specific tag creation and SBOM scan jobs to validate SBOM generation, vulnerability scanning, and attestation against the midnightntwrk registry before integrating into production workflows.
imagetools-created arch tags are OCI indexes, not single-platform manifests, so syft on amd64 runners can't resolve arm64-only indexes.
…ion workflows Add image copy, cosign signing, and SBOM scanning/attestation for ghcr.io/midnightntwrk in both main and release workflows. Arch-specific tags are created alongside multi-arch manifests to support per-platform SBOM attestation. - main.yml: copy+sign commit-tagged and latest-main images, 4 SBOM jobs - release-image.yml: copy+sign release images, 2 SBOM jobs gating release - verify-image.sh: add midnightntwrk prefixes - docs: update signed images table, add operator verification guide
Contributor
bb109ea to
4018db8
Compare
Adds attest_sbom_to_multiarch() which attests each per-platform SBOM against the manifest list digest, enabling cosign verify-attestation on multi-arch tags. Test workflow includes a verification job.
…tations cosign-installer v3.7.0 installed cosign v2.4.1 which stores attestations via tag-based discovery (.att tag). cosign v3+ stores them as OCI referrers (--new-bundle-format=true default). Since signatures are already stored as OCI referrers, cosign verify-attestation only checked referrers and never fell back to tag-based, causing multi-arch attestation verification to fail.
cosign verify-attestation dumps full SBOM JSON payloads to stdout, which can be megabytes and cause the step to hang printing output.
…lows Pass multi-arch-image to midnightntwrk SBOM jobs in main.yml and release-image.yml so per-platform SBOMs are attested against the manifest list digest, enabling cosign verify-attestation on multi-arch tags.
Earthly now pushes arch-specific commit-tagged images directly to ghcr.io/midnightntwrk in addition to ghcr.io/midnight-ntwrk. Workflow steps that create multi-arch manifests, latest-main tags, release tags, and Docker Hub images for midnightntwrk now source from midnightntwrk instead of midnight-ntwrk, removing the cross-registry dependency. All midnight-ntwrk operations remain completely unchanged.
…ch SBOM attestation Replace string-based command building with bash arrays to avoid eval, and add a verification step after multi-arch SBOM attestation.
gilescope
approved these changes
Feb 11, 2026
14 tasks
gilescope
pushed a commit
that referenced
this pull request
Apr 8, 2026
m2ux
added a commit
that referenced
this pull request
Apr 23, 2026
Signed-off-by: Mike Clay <mike.clay@shielded.io>
m2ux
added a commit
that referenced
this pull request
Apr 23, 2026
Signed-off-by: Mike Clay <mike.clay@shielded.io>
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.








Overview
Publish midnight-node and midnight-node-toolkit images to
ghcr.io/midnightntwrk(the org-matching GHCR namespace) alongside the existingghcr.io/midnight-ntwrkand Docker Hub registries. All images are cosign-signed and SBOM-attested.What this does
Build (
Earthfile):ghcr.io/midnight-ntwrkandghcr.io/midnightntwrksimultaneously during Earthly builds (no cross-registry copy needed)Production workflows (
main.yml,release-image.yml):midnightntwrkfrom its own arch-specific tags viadocker buildx imagetools createsbom-scan-image.ymlfinalize-releaseon midnightntwrk SBOM resultsghcr.io/midnightntwrk(instead ofghcr.io/midnight-ntwrk), makingmidnightntwrkthe canonical upstreamSigning infrastructure (
sign-image.sh):SBOM infrastructure (
sbom-scan-image.yml,sbom-scan.sh):--platformparameter support for cross-platform SBOM generation on manifest-list imagescosign verify-attestationon multi-arch tags without--platform(which cosign doesn't support — verify-attestation should support --platform argument sigstore/cosign#3552)multi-arch-imageoptional input onsbom-scan-image.ymlreusable workflowVerification (
verify-image.sh, docs):🗹 TODO before merging
.github/workflows/test-ghcr-midnightntwrk-push.ymltest workflow📌 Submission Checklist
🧪 Testing Evidence
Test workflow (
test-ghcr-midnightntwrk-push.yml) validated end-to-end on this branch:Arch-specific image push to both GHCR registries via Earthly
Multi-arch manifest creation in
midnightntwrkfrom its own arch tagsCosign keyless signing with GitHub Actions OIDC
Signature verification with certificate identity + OIDC issuer
SBOM generation (Syft), vulnerability scanning (Grype), attestation (Cosign)
Multi-arch SBOM attestation: per-platform SBOMs attested to manifest list digest
Multi-arch SBOM verification:
cosign verify-attestation --type spdxjsonon multi-arch tags passesAll Rekor transparency log entries confirmed
Additional tests are provided (if possible)
🔱 Fork Strategy
Links
- JIRA: SRE-1769