Let a release survive Harbor's scan and re-run past existing tags #1

Merged
Patrick merged 1 commit from patrick/rerunnable-release into main 2026-10-29 20:57:24 -04:00 AGit
Owner

Makes orbital-cosign.yml survive Harbor's scan-on-push and safe to re-run. Both problems hit orbital v0.3.20 and v0.3.21.

1. Signing raced Harbor's vulnerability scan
The orbital project blocks pulling an image while its scan is running. cosign reads the image to sign it, so for a large image (asterisk) signing straight after the push failed with PROJECTPOLICYVIOLATION ... vulnerability scan is in "Running" status. Signing now retries every 15s, up to 10 minutes, only for that error. Any other cosign error still fails right away.

2. Re-running a release failed on immutable version tags
Once an image's X.Y.Z tag is pushed, Harbor refuses to push it again, so re-running a partly failed release could never get past the push and the chart was never published. Before pushing each extra (version) tag, the step now checks what the registry already has:

  • the same digest as this build: skip the push
  • a different digest: fail, telling you to release a new version

latest and the commit-SHA tag are pushed as before.

Also: curl -f --retry 5 for the cosign download.

🤖 Generated with Claude Code

https://claude.ai/code/session_015nhjTULCMboQBz71VUawYr

Makes `orbital-cosign.yml` survive Harbor's scan-on-push and safe to re-run. Both problems hit orbital v0.3.20 and v0.3.21. **1. Signing raced Harbor's vulnerability scan** The `orbital` project blocks pulling an image while its scan is running. cosign reads the image to sign it, so for a large image (asterisk) signing straight after the push failed with `PROJECTPOLICYVIOLATION ... vulnerability scan is in "Running" status`. Signing now retries every 15s, up to 10 minutes, only for that error. Any other cosign error still fails right away. **2. Re-running a release failed on immutable version tags** Once an image's `X.Y.Z` tag is pushed, Harbor refuses to push it again, so re-running a partly failed release could never get past the push and the chart was never published. Before pushing each extra (version) tag, the step now checks what the registry already has: - the same digest as this build: skip the push - a different digest: fail, telling you to release a new version `latest` and the commit-SHA tag are pushed as before. **Also:** `curl -f --retry 5` for the cosign download. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_015nhjTULCMboQBz71VUawYr
Let a release survive Harbor's scan and re-run past existing tags
Some checks failed
orbital-cosign.yml / Let a release survive Harbor's scan and re-run past existing tags (pull_request) Failing after 0s
orbital-cosign.yml / Merge pull request 'Let a release survive Harbor's scan and re-run past existing tags' (#1) from patrick/rerunnable-release into main (pull_request) Failing after 0s
3d09a14bcf
Two ways orbital releases failed after their images were pushed:

- Harbor scans each image on push and refuses to serve it while the
  scan runs (project vulnerability policy). cosign reads the image to
  sign it, so a large image (asterisk) could be refused with
  PROJECTPOLICYVIOLATION ... "Running". Signing now retries every 15s
  for up to 10 minutes while that is the reason.
- Version tags are immutable, so re-running a release that already
  pushed X.Y.Z failed on that push. A version tag that already points
  at the image just built is now skipped; one that points at a
  different image fails with a clear message.

Also retry the cosign download and fail on HTTP errors instead of
installing an error page as the binary.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015nhjTULCMboQBz71VUawYr
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
actions/.forgejo-workflows!1
No description provided.