Skip to content

retry cosign - #1714

Merged
skudasov merged 1 commit into
mainfrom
retry-cosign
Oct 21, 2026
Merged

skudasov merged 1 commit into
mainfrom
retry-cosign

Conversation

@skudasov

@skudasov skudasov commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

In the scope of https://smartcontract-it.atlassian.net/browse/DX-5631, we've figured out that sometimes the cosign action may fail temporarily https://github.com/smartcontractkit/chipotle/actions/runs/39308447686; hence, this PR adds retries.

@skudasov
skudasov requested a review from a team as a code owner October 21, 2026 15:08
@github-actions

Copy link
Copy Markdown
Contributor

👋 skudasov, thanks for creating this pull request!

To help reviewers, please consider creating future PRs as drafts first. This allows you to self-review and make any final changes before notifying the team.

Once you're ready, you can mark it as "Ready for review" to request feedback. Thanks!

@github-actions

Copy link
Copy Markdown
Contributor

🦋 Changeset is good to go

Latest commit: f82747c

We got this.

Not sure what this means? Click here to learn what changesets are.

# Retry to absorb transient OIDC/Fulcio/Rekor errors. Signing the same
# digest again is safe: it only adds another signature.
for (( attempt = 1; attempt <= ATTEMPTS; attempt++ )); do
if cosign sign "${MANIFEST_NAME_WITH_DIGEST}" --yes; then

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NIT: do we want to add an exponencial backoff or some delay? trying it in sequence can lead to same fail if underlying service is going through a "hiccup"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok. the input already defines it: cosign-sign-retry-interval-seconds

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that if cosign will be failing all our attempts we better fail the CI then and look how we can work it around another way (use other tool?). We can't wait an additional 5-10 minutes in CI because it'd be on the path of all the entire auto-CD pipeline in main.

@skudasov
skudasov merged commit eeaf39b into main Oct 21, 2026
20 checks passed
@skudasov
skudasov deleted the retry-cosign branch October 21, 2026 16:26
@gati-app gati-app Bot mentioned this pull request Oct 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants