Skip to content

Sign only on a release tag push or an explicit dispatch - #78

Merged
xroche merged 1 commit into
masterfrom
harden-sign-trigger
Jul 29, 2026
Merged

Sign only on a release tag push or an explicit dispatch#78
xroche merged 1 commit into
masterfrom
harden-sign-trigger

Conversation

@xroche

@xroche xroche commented Jul 29, 2026

Copy link
Copy Markdown
Owner

The sign job tested startsWith(github.ref, 'refs/tags/') || inputs.sign. That first condition is true for a workflow_dispatch launched from a tag ref, not only for a tag push, so dispatching the workflow from any tag queued a signing run, approval prompt included, with sign still false. It now tests the event: a push whose ref is a tag, or a dispatch that asked to sign.

This goes with two settings changed outside the repo tree: a tag ruleset restricting tag creation to the admin account, and a deployment branch policy on the signing environment limiting it to master and the release tag patterns.

The sign job tested `startsWith(github.ref, 'refs/tags/')`, which is true for a
workflow_dispatch launched from a tag ref as well as for a tag push. Dispatching
the workflow from any tag therefore queued a signing run with `sign` left false.

Test the event instead: a push whose ref is a tag (already filtered to the
release patterns by `on.push.tags`), or a dispatch that asked for it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012gAp9x4L95B8DkeuHQpuqg
Signed-off-by: Xavier Roche <roche@httrack.com>
@xroche
xroche enabled auto-merge (squash) July 29, 2026 06:25
@xroche
xroche merged commit 50a112e into master Jul 29, 2026
4 checks passed
@xroche
xroche deleted the harden-sign-trigger branch July 29, 2026 06:30
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.

1 participant