CI cuts a Release for every published Image #52

Closed
opened 2026-10-10 11:33:36 +00:00 by piscis · 0 comments
Owner

Parent

#45

What to build

Every Image CI publishes gets its Release right away, so the Releases page can't drift from the registry.

  • In the publish job, after the publish step succeeds, CI creates a Release if none exists yet for the current Image tag. This only runs when publishing runs: a push to main or a dispatch from main.
    • It doesn't matter whether this run pushed the Image. A re-run after a failed release step repairs the missing Release, and the publish script needs no new exit code.
    • A push to main that doesn't change the Pin finds the Release already there and creates nothing.
  • It runs in the existing publish concurrency group. The checkout keeps not persisting git credentials, and nothing is pushed to git.
  • Token: try the run's automatic Actions token first. If it can't create releases, add a release-token secret for the existing bot user, scoped to repository write, and give the bot write access. Don't widen the registry token. Record the outcome as a one-line gotcha in the Forgejo agent doc.
  • The README's tag section points Consumers to the Releases page.

Acceptance criteria

  • After this lands, one dispatch on main leaves exactly one Release for the current Image tag, and running it again doesn't change that
  • The Release's git tag targets the commit the Image was built from
  • Pull request runs never create a Release
  • The token outcome is recorded in the Forgejo agent doc
  • The README points to the Releases page

Blocked by

## Parent #45 ## What to build Every Image CI publishes gets its Release right away, so the Releases page can't drift from the registry. - In the publish job, after the publish step succeeds, CI creates a Release if none exists yet for the current Image tag. This only runs when publishing runs: a push to main or a dispatch from main. - It doesn't matter whether this run pushed the Image. A re-run after a failed release step repairs the missing Release, and the publish script needs no new exit code. - A push to main that doesn't change the Pin finds the Release already there and creates nothing. - It runs in the existing publish concurrency group. The checkout keeps not persisting git credentials, and nothing is pushed to git. - **Token:** try the run's automatic Actions token first. If it can't create releases, add a release-token secret for the existing bot user, scoped to repository write, and give the bot write access. Don't widen the registry token. Record the outcome as a one-line gotcha in the Forgejo agent doc. - The README's tag section points Consumers to the Releases page. ## Acceptance criteria - [ ] After this lands, one dispatch on main leaves exactly one Release for the current Image tag, and running it again doesn't change that - [ ] The Release's git tag targets the commit the Image was built from - [ ] Pull request runs never create a Release - [ ] The token outcome is recorded in the Forgejo agent doc - [ ] The README points to the Releases page ## Blocked by - #51
Sign in to join this conversation.
No description provided.