ci(gitea): warn before the Gitea release key stops verifying releases #288

Merged
Defame1297 merged 3 commits from ci/gitea-release-key into main 2026-11-22 08:30:41 +00:00
3 Commits
Author SHA1 Message Date
Defame1297 957dd4f95f Merge branch 'main' into ci/gitea-release-key
Build / build (pull_request) Successful in 17s
Gitea release key / check (pull_request) Successful in 23s
Lint / lint (pull_request) Successful in 50s
Molecule / molecule (pull_request) Successful in 19m44s
2026-11-22 08:08:09 +00:00
Defame1297 a7b9f47496 Merge branch 'main' into ci/gitea-release-key
Build / build (pull_request) Successful in 16s
Gitea release key / check (pull_request) Successful in 8s
Lint / lint (pull_request) Successful in 52s
Molecule / molecule (pull_request) Canceled after 7m59s
2026-11-22 07:37:50 +00:00
Defame1297andClaude Opus 5.5 0837cc387f ci(gitea): warn before the Gitea release key stops verifying releases
Build / build (pull_request) Successful in 15s
Gitea release key / check (pull_request) Successful in 9s
Lint / lint (pull_request) Successful in 51s
Molecule / molecule (pull_request) Canceled after 36s
The gitea role accepts a release only when it carries a valid signature by
gitea_gpg_key_id or one of its subkeys, so an expired, revoked or replaced
Gitea release key makes every install and update fail closed, without
warning, on the day it happens.

scripts/check_gitea_release_key.py reads the pins from the role defaults,
fetches the release key into a throwaway keyring and only the .asc of the
pinned release (never the binary), and fails when the primary key or a
signing subkey expires within 60 days, is revoked or expired, or when a
signature in the .asc is not by a valid signing key of the pinned key. Its
docstring says what to do on a failure.

The Gitea release key workflow runs it weekly, by hand, and on pull requests
that change the role defaults or the check, so a gitea_version bump is
checked against the new release's signature. It runs in the ci image at the
pin of lint.yml; that image has gpgv but not gpg, so the job installs gpg and
gpg-agent from the Ubuntu archive per run instead of making the check an
image input. The tests that make keys skip without gpg, so the Lint job's
unittest run (no gpg) still covers the parsing and rendering tests.

The workflow pins the ci image, so it joins the pin consumers of
check_image_versions.py and check_bot_pr_diff.py: Renovate's pin follow-up
edits every workflow, and the bot-diff gate would otherwise refuse that pull
request. The new workflow and script are on the molecule selector's IGNORED
list, since no scenario reads them.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
2026-11-22 07:29:31 +00:00