Promote and delete referrers with the image (OCI 1.0 + 1.1) - #200
Merged
Conversation
Referrers (SBOM/provenance/VEX/signatures) were dropped on the standard promote path and left dangling in quarantine after the image tag was deleted. This makes the referrer graph travel with the subject and be cleaned up with it. Copy: all three promote paths now set copy-referrers=true so oras cp -r carries the index, child manifests and their referrers to golden. - _promote-from-quarantine.yml: add copy-referrers to the promote step. - _promote-override.yml: always copy referrers (was sbom-only). Delete: delete-image now removes the tag's referrer closure before the image — every OCI 1.1 referrer manifest (untagged version, by digest) and OCI 1.0 sha256-<subject> fallback index, for the image index and each child manifest, discovered recursively (referrers-of-referrers). Best-effort and idempotent; degrades to image-only when crane/oras are not logged in. Adds delete-referrers input (default true) and a referrers-deleted output. Refs #198
Contributor
There was a problem hiding this comment.
Pull request overview
Extends the promotion and cleanup workflows so OCI referrers (OCI 1.0 + 1.1) move with promoted images and are cleaned up from quarantine when deleting an image tag, aligning registry behavior with #198.
Changes:
- Enable referrer-aware promotion in quarantine→golden paths by always copying referrers during image promotion.
- Enhance
delete-imagecomposite action to (optionally) delete the full referrer closure (including referrers-of-referrers) before deleting the image tag. - Update workflow action reference docs to describe the new
delete-referrersinput andreferrers-deletedoutput.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| docs/reference/workflow-actions.md | Documents referrer-closure deletion behavior, new input, and new output. |
| .github/workflows/_promote-override.yml | Always sets copy-referrers=true so manual overrides also promote referrers. |
| .github/workflows/_promote-from-quarantine.yml | Passes copy-referrers: "true" to ensure referrers are copied during promotion. |
| .github/actions/delete-image/action.yml | Adds delete-referrers behavior and emits referrers-deleted output. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Copilot review: the early token-empty exit set status=skipped but never wrote referrers-deleted, leaving it unset for callers. Emit 0.
This was referenced Aug 14, 2026
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.
Implements the registry side of #198 (companion observability issue: #199).
Problem
crane copy(nocopy-referrers), so OCI referrers (acquisition provenance, SBOM, VEX, signatures) were not carried to golden.sha256-*fallback) dangling in quarantine.Changes
Copy — all three promote paths now copy referrers (
oras cp -r, already inmirror-image, carries the index + child manifests + their referrers, preserving digests sosubjectlinks stay valid):_promote-from-quarantine.yml:copy-referrers: "true"on the promote step._promote-override.yml: always copy referrers (was sbom-method-only)._promote-from-quarantine-sbom.yml: alreadytrue(unchanged).Delete —
delete-imageremoves the referrer closure before the image:oras discovers referrers recursively (referrers-of-referrers, e.g. a signature on an SBOM)..namedigest) and each OCI 1.0sha256-<subject-digest>fallback index.delete-referrersinput (defaulttrue) andreferrers-deletedoutput. Best-effort/idempotent; degrades to image-only when crane/oras aren't logged in (the promote jobs are).Validation
shellcheckclean on the delete-image script.actionlintclean for the edited steps (pre-existing info/style warnings in untouched jobs remain).workflow-actions.md) updated.Not in this PR
Refs #198