ci(images): assign image versions in CI and open the pin PR right after a push #165
Notifications
Due Date
No due date set.
Blocks
Depends on
#135 ci(roles): repeat defaults in argument_specs and fail when they drift from defaults/main.yml
Mortis/Kamino
#169 refactor(images): image docs next to the images, check_image_versions.py pins only
Mortis/Kamino
#171 refactor: cut scripts, workflow headers and comments down to the code-style rules
Mortis/Kamino
#184 ci(lint): check Markdown links offline with lychee
Mortis/Kamino
#128 docs: remove the ADR 0004 citations
Mortis/Kamino
Reference: Mortis/Kamino#165
Reference in new issue
Block a user
Spec: CI image pipeline: keep, simplify or replace, resolution sections 3 and 4.
What
version:lines from theimage.ymlbuild matrix. Each image gets a smallbase:line (MAJOR.MINOR) that a human edits only for a minor or major.matrix_ofandcheck_pinsinscripts/check_image_versions.pyto thebase:matrix, the smallest change that keepscheck_image_versions.py pinspassing. The check that a consumer pin is not newer than the matrix version goes, since the matrix holds no version. Remove Lint's "Check image versions were bumped" step in.gitea/workflows/lint.yml. The rest of that script's rewrite stays with refactor(images): image docs next to the images, check_image_versions.py pins only.main, the image job computes a checksum of the image's inputs and compares it with the input-checksum label of the newest published<base>.x. If they differ, it publishes the next patch as<version>andlatest, with the checksum as a label. If they match, it ends without building. A published tag is never moved.renovate.ymlgetson: workflow_run: workflows: [Images], types: [completed], runs live (not as a dry run), and is guarded onconclusion == 'success'. A manual dispatch of the Renovate workflow is a dry run unless its input is exactly the string "false", soimage.ymldoes not dispatch it. Gitea implementsworkflow_run; it needs no token, no API call and no input. Check first that aworkflow_runstarted by an Actions-triggered run is not filtered out. Fallback if it is: a separate job withneeds:on the image job that dispatches withinputs: {dry_run: "false"}; name the credential it uses (never the registry secret), and verify that the job token may dispatch.scripts/bump_image_versions.pyand its tests, thebumpmode ofcheck_image_versions.py, Renovate's post-upgrade task, and the bot-diff gate's allowance for matrixversion:lines. Update the two-PR loop text inimages/AGENTS.md(and in the rootAGENTS.md, if it has a line on it).Acceptance
The registry credential stays in
image.ymlonly. The Renovate trigger must not hand it on.Open proposals
Order: this now waits on the contributor-doc split (#189) where it edits
CONTRIBUTING.md, and on docs(agents): replace CLAUDE.md with a root AGENTS.md (#185): put theCLAUDE.mdedits in the root or nestedAGENTS.mdinstead. (From Order of the implementation backlog, #198.)Review of the map (2026-11-15): corrections to this issue.
image.ymldispatches the Renovate workflow"..gitea/workflows/renovate.yml:73-75: "A manual dispatch is a dry run unless the input is exactly the string "false"", andDRY_RUNis true for anyworkflow_dispatchwithout it. Taken literally, the run logs a dry run and the pin PR never opens..gitea/workflows/image.yml:309-313: when the executor finishes, the job container's filesystem is the built image, and the shell "needs only builtins by then". Acurlcall to the dispatch API in that job may find nocurl.on: workflow_run: workflows: [Images], types: [completed]inrenovate.yml, run live, guarded onconclusion == 'success'. Gitea implementsworkflow_run; it needs no token, no API call and no input. Check first that aworkflow_runstarted by an Actions-triggered run is not filtered out. Fallback: a separate job withneeds:on the image job that dispatches withinputs: {dry_run: "false"}; name the credential it uses (never the registry secret), and verify that the job token may dispatch.version:in the PR that changes an image" and the two-PR loop intoimages/AGENTS.md. Change: addimages/AGENTS.md(and the rootAGENTS.md, if it has a line on it) to the files this issue updates.Review of the map (2026-11-17).
image.ymldispatches the Renovate workflow" and "Update the two-PR loop text inCLAUDE.mdandCONTRIBUTING.md" are replaced by the comment of 2026-11-16 (workflow_run;images/AGENTS.md).Moved to Continuous delivery by Which issues must land before the first friend (question 1). It no longer blocks zizmor, the apm trim or refuse CLAUDE.md by hook: each builds today with the manual PATCH bump, so the edges failed the order decision's hard test. Its other edges are unchanged.
Final validation round, second pass (2026-11-20): body edited.
matrix_ofandcheck_pinsinscripts/check_image_versions.pyto thebase:matrix (the pin-not-newer check goes) and the removal of Lint's "Check image versions were bumped" step; the rest of the script's rewrite stays with the image-layout issue.renovate.ymlruns onworkflow_runof Images, live, guarded on success (a dispatch is a dry run), with the fallback job; the two-PR loop text goes inimages/AGENTS.md(and the rootAGENTS.mdif it has a line), notCLAUDE.mdandCONTRIBUTING.md; the acceptance no longer passes on a dry run.Observed after the merges of #340 and #341 (2026-11-23, from the run records):
net.rkdr.mortis.inputs-sha256label. It finished at 22:22:10.workflow_run) started at 22:22:11 and ran live.workflow_runafter the failed run 5229 was skipped (run 5231), as the success guard intends.Against the proposal of 15 minutes for "the pin PR exists within N minutes of the image push", this is well inside it. The number itself is the maintainer's.
Still open: a run whose inputs are unchanged building nothing. A manual dispatch of Images from
mainis checking that next.Confirmed: a run with unchanged inputs publishes nothing.
main) succeeded. Each of the three jobs logged "Inputs of mortis/ are unchanged since its newest version: nothing to publish." and skipped the build. Each job took 13–20 s once it had a runner. The newest tags are still 0.1.10, 0.1.6 and 0.2.39.workflow_runevent in the same second it completed. It ran live and opened no pull request.Acceptance status:
Assisted-by: Claude Code
Decision (maintainer): the pin PR exists within 15 minutes of the image push. Observed: about 15 seconds (Images run 5236 → pin PRs #342–#344).
Assisted-by: Claude Code