Does this repository keep building its own three CI images with the version, pin and two-PR machinery around them, or is there a simpler arrangement that still gives fast, reproducible CI?
Context
The machinery: image.yml, scripts/check_image_versions.py, scripts/bump_image_versions.py, part of scripts/check_bot_pr_diff.py, their tests, and roughly half of CLAUDE.md. A contributor has to understand it to bump one tool.
Constraints that made it this way: molecule needs systemd-capable images; each pushed layer must stay under 100 MB; one digest per version; the job that pushes holds a registry credential.
Whether a simpler option holds up is not known; that is the point of the ticket.
Stretches the map's scope slightly: this is CI architecture, not only rules. Any change needs the maintainer's approval of the specific plan.
Part of #87
## Question
Does this repository keep building its own three CI images with the version, pin and two-PR machinery around them, or is there a simpler arrangement that still gives fast, reproducible CI?
## Context
- The machinery: `image.yml`, `scripts/check_image_versions.py`, `scripts/bump_image_versions.py`, part of `scripts/check_bot_pr_diff.py`, their tests, and roughly half of `CLAUDE.md`. A contributor has to understand it to bump one tool.
- Constraints that made it this way: molecule needs systemd-capable images; each pushed layer must stay under 100 MB; one digest per version; the job that pushes holds a registry credential.
- Whether a simpler option holds up is not known; that is the point of the ticket.
- Stretches the map's scope slightly: this is CI architecture, not only rules. Any change needs the maintainer's approval of the specific plan.
From Public design contract replacing the ADR 0004 references: image distribution (pinning by version and digest, a published tag never moved or rebuilt) is an ADR candidate. This ticket decides whether its outcome meets the ADR bar (hard to reverse, surprising, a real trade-off) and, if so, the closing session files the ADR as implementation. ADRs: status accepted or superseded by NNNN, one screen at most, a residual-risk section only when a risk is accepted, no infrastructure detail.
From [Public design contract replacing the ADR 0004 references](https://git.rkdr.net/Mortis/Kamino/issues/92): image distribution (pinning by version and digest, a published tag never moved or rebuilt) is an ADR candidate. This ticket decides whether its outcome meets the ADR bar (hard to reverse, surprising, a real trade-off) and, if so, the closing session files the ADR as implementation. ADRs: status `accepted` or `superseded by NNNN`, one screen at most, a residual-risk section only when a risk is accepted, no infrastructure detail.
One doc for both molecule images: docs/images/molecule-ubuntu2404.md and molecule-ubuntu2604.md differ only in the release, the gnupg line, the image variable and the smoke scenario.
Image docs live next to their images under images/ so they are found together (leaning: images/ci/README.md and one images/molecule-ubuntu.md, or wherever a restructured image layout puts them).
A doc edit is not an image input: *.md under images/ is excluded in bump_image_versions.py, check_image_versions.py (bump and the docs-exist check) and the Renovate rule description. The documentation labels point at the new paths (a label edit is an input: bump both molecule images).
The doc's line about "the home lab's LXC hosts" goes.
Input from [Resolve stale and contradictory claims](https://git.rkdr.net/Mortis/Kamino/issues/95), decided there; the exact layout is this ticket's:
- One doc for both molecule images: `docs/images/molecule-ubuntu2404.md` and `molecule-ubuntu2604.md` differ only in the release, the `gnupg` line, the image variable and the smoke scenario.
- Image docs live next to their images under `images/` so they are found together (leaning: `images/ci/README.md` and one `images/molecule-ubuntu.md`, or wherever a restructured image layout puts them).
- A doc edit is not an image input: `*.md` under `images/` is excluded in `bump_image_versions.py`, `check_image_versions.py` (bump and the docs-exist check) and the Renovate rule description. The `documentation` labels point at the new paths (a label edit is an input: bump both molecule images).
- The doc's line about "the home lab's LXC hosts" goes.
Defame1297
was assigned by Claude2026-11-15 13:50:17 +00:00
Keep the self-built images; cut the machinery around them. The maintainer weighs CI speed as heavily as simplicity: complexity bought for speed is allowed, but only as a conscious, recorded choice with its measured saving. Each layer was judged on its own.
1. The ci image stays, as a recorded speed choice
Measured: Lint about 82s without the image (Oct 24–25, everything installed per run) vs 15–25s with it; Build about 50s vs 10–25s. The slow path (a PR changing pins) costs 46–94s, mostly Go hook builds (gitleaks about 31s, actionlint about 9.5s).
Its header carries these numbers so a later reader can check it still pays.
Rule (bake in): every tool, collection, hook environment and package a CI job uses is in its image; a job downloads at runtime only when a pull request changes a pin (the slow path); a new runtime download is a defect. Held by review, plus a control if cheap: run the Lint/Build fast path with the network off.
Rule (recorded speed): a speed optimisation that adds machinery states its measured saving where it lives. Held by review.
2. Molecule images stay self-built
One Dockerfile images/molecule-ubuntu/Dockerfile with a RELEASE build argument; two matrix entries and two image names remain. Condition: Renovate (custom regex manager) keeps tracking both base digests; otherwise keep two files.
Test fixtures a scenario's prepare.yml installs are baked in. Packages the role itself installs stay runtime downloads: that install path is what the test exercises.
3. Versions: semver kept, assigned by CI
The version: lines leave the image.yml matrix. On main, the image job compares the image's inputs (checksum recorded as an image label) with the newest published version and, if they changed, publishes the next patch. A minor or major is a hand edit of a small per-image base: line.
Goes: bump_image_versions.py and tests, check_image_versions.py bump, the "bump in the same PR" rule, Renovate's post-upgrade task, the bot-diff gate's version: exception. A published tag is still never moved.
4. The pin follows the build at once
image.yml dispatches the Renovate workflow after it pushes a new version, so the pin PR opens within minutes instead of on the schedule (the last pin PR was opened by hand after the hourly limit ran out; the merge-to-pin gap was 23 min to 6h40m). Whether it automerges is Renovate automerge posture's.
5. check_image_versions.py: pins mode only
Keeps the checks that catch real mistakes (job_image release equals the Dockerfile FROM, label block complete, no production namespace in workflows, the image doc exists), rewritten for the new layout, as small as it goes, each check with a one-line reason.
6. Image docs next to the images
images/ci/README.md and one doc for both molecule images; *.md under images/ is not an image input; the documentation labels point at the new paths; the "home lab's LXC hosts" line goes. (Owed from Resolve stale and contradictory claims.)
7. Queue and Molecule
Measured: a full Molecule run is about 8 min (ufw 153s, system_baseline 94s; about 15s fixed per scenario); one role is 50–110s. The worst PR waited 13m42s, almost all queued behind a full run and a ci build on the single slot.
Capacity 2 on the current runner (no second runner for now; maybe later). Molecule jobs share one concurrency: group so they never overlap and queue without holding a slot; fallback flock on the host if this Gitea lacks concurrency:. The stale-container cleanup only removes containers carrying a Molecule label. The capacity change itself is the maintainer's, in the environment repository.
A push to main runs only the scenarios its diff selects, as a PR does; the nightly full run is the safety net. Residual risk: two PRs that pass alone but break together are caught by the nightly. Recommended setting (maintainer's): require branches to be up to date before merging.
8. ADR: yes
Image distribution meets the bar (hard to reverse, surprising, a real trade-off). One ADR: Self-built CI and molecule images, versioned by CI, pinned by version and digest, with the measured saving and the residual risk that an image-input PR is not tested in its own image until the pin PR's CI.
Evidence
Run and job data from 2026-10-24 to 2026-11-15 (Gitea Actions): fast-path Lint jobs 3400, 3456, 3700, 4722, 4732; slow path 4672, 4526; pre-image Lint/Build 2254–2290; full Molecule 3986/4693, 3977, 3974, 3962; queue 3968 (13m42s), 3989; pin PR 153 vs image PRs 146, 148, 151. ci went 0.1.0 → 0.2.23 in three weeks (9 versions on Nov 14–15). Not verified: that actions/cache works on this runner; that this Gitea supports concurrency: and ${{ needs.* }} in container.image.
## Resolution
**Keep the self-built images; cut the machinery around them.** The maintainer weighs CI speed as heavily as simplicity: complexity bought for speed is allowed, but only as a conscious, recorded choice with its measured saving. Each layer was judged on its own.
### 1. The `ci` image stays, as a recorded speed choice
- Measured: Lint about 82s without the image (Oct 24–25, everything installed per run) vs 15–25s with it; Build about 50s vs 10–25s. The slow path (a PR changing pins) costs 46–94s, mostly Go hook builds (gitleaks about 31s, actionlint about 9.5s).
- Its header carries these numbers so a later reader can check it still pays.
- **Rule (bake in):** every tool, collection, hook environment and package a CI job uses is in its image; a job downloads at runtime only when a pull request changes a pin (the slow path); a new runtime download is a defect. Held by review, plus a control if cheap: run the Lint/Build fast path with the network off.
- **Rule (recorded speed):** a speed optimisation that adds machinery states its measured saving where it lives. Held by review.
### 2. Molecule images stay self-built
- One Dockerfile `images/molecule-ubuntu/Dockerfile` with a `RELEASE` build argument; two matrix entries and two image names remain. Condition: Renovate (custom regex manager) keeps tracking both base digests; otherwise keep two files.
- Test fixtures a scenario's `prepare.yml` installs are baked in. Packages the role itself installs stay runtime downloads: that install path is what the test exercises.
### 3. Versions: semver kept, assigned by CI
- The `version:` lines leave the `image.yml` matrix. On `main`, the image job compares the image's inputs (checksum recorded as an image label) with the newest published version and, if they changed, publishes the next patch. A minor or major is a hand edit of a small per-image `base:` line.
- Goes: `bump_image_versions.py` and tests, `check_image_versions.py bump`, the "bump in the same PR" rule, Renovate's post-upgrade task, the bot-diff gate's `version:` exception. A published tag is still never moved.
### 4. The pin follows the build at once
- `image.yml` dispatches the Renovate workflow after it pushes a new version, so the pin PR opens within minutes instead of on the schedule (the last pin PR was opened by hand after the hourly limit ran out; the merge-to-pin gap was 23 min to 6h40m). Whether it automerges is [Renovate automerge posture](https://git.rkdr.net/Mortis/Kamino/issues/97)'s.
### 5. `check_image_versions.py`: `pins` mode only
Keeps the checks that catch real mistakes (job_image release equals the Dockerfile `FROM`, label block complete, no production namespace in workflows, the image doc exists), rewritten for the new layout, as small as it goes, each check with a one-line reason.
### 6. Image docs next to the images
`images/ci/README.md` and one doc for both molecule images; `*.md` under `images/` is not an image input; the `documentation` labels point at the new paths; the "home lab's LXC hosts" line goes. (Owed from [Resolve stale and contradictory claims](https://git.rkdr.net/Mortis/Kamino/issues/95).)
### 7. Queue and Molecule
- Measured: a full Molecule run is about 8 min (ufw 153s, system_baseline 94s; about 15s fixed per scenario); one role is 50–110s. The worst PR waited 13m42s, almost all queued behind a full run and a `ci` build on the single slot.
- **Capacity 2** on the current runner (no second runner for now; maybe later). Molecule jobs share one `concurrency:` group so they never overlap and queue without holding a slot; fallback `flock` on the host if this Gitea lacks `concurrency:`. The stale-container cleanup only removes containers carrying a Molecule label. The capacity change itself is the maintainer's, in the environment repository.
- **A push to `main` runs only the scenarios its diff selects**, as a PR does; the nightly full run is the safety net. Residual risk: two PRs that pass alone but break together are caught by the nightly. Recommended setting (maintainer's): require branches to be up to date before merging.
### 8. ADR: yes
Image distribution meets the bar (hard to reverse, surprising, a real trade-off). One ADR: *Self-built CI and molecule images, versioned by CI, pinned by version and digest*, with the measured saving and the residual risk that an image-input PR is not tested in its own image until the pin PR's CI.
## Evidence
Run and job data from 2026-10-24 to 2026-11-15 (Gitea Actions): fast-path Lint jobs 3400, 3456, 3700, 4722, 4732; slow path 4672, 4526; pre-image Lint/Build 2254–2290; full Molecule 3986/4693, 3977, 3974, 3962; queue 3968 (13m42s), 3989; pin PR 153 vs image PRs 146, 148, 151. `ci` went 0.1.0 → 0.2.23 in three weeks (9 versions on Nov 14–15). Not verified: that `actions/cache` works on this runner; that this Gitea supports `concurrency:` and `${{ needs.* }}` in `container.image`.
Partly superseded by Molecule and Renovate on the shared runner: isolation, capacity and cost: one Dockerfile per image, with no release build argument (section 2). Molecule runs are kept apart by per-run isolation, with no shared concurrency group, and Molecule does not run on push to main (section 7).
Section 8's residual risk ("an image-input PR is not tested in its own image until the pin PR's CI") now also covers an ansible-core bump, which a later decision says is tested by its own pull request. Open in What Molecule proves before a merge, and who acts on the nightly run.
Review of the map (2026-11-17).
Partly superseded by [Molecule and Renovate on the shared runner: isolation, capacity and cost](https://git.rkdr.net/Mortis/Kamino/issues/212): one Dockerfile per image, with no release build argument (section 2). Molecule runs are kept apart by per-run isolation, with no shared concurrency group, and Molecule does not run on push to `main` (section 7).
Section 4's open point is closed by [Code-owner approval against Renovate automerge, and where secrets live](https://git.rkdr.net/Mortis/Kamino/issues/210): the pin-follow pull request waits for one maintainer approval per image build.
Section 8's residual risk ("an image-input PR is not tested in its own image until the pin PR's CI") now also covers an ansible-core bump, which a later decision says is tested by its own pull request. Open in [What Molecule proves before a merge, and who acts on the nightly run](https://git.rkdr.net/Mortis/Kamino/issues/256).
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Part of #87
Question
Does this repository keep building its own three CI images with the version, pin and two-PR machinery around them, or is there a simpler arrangement that still gives fast, reproducible CI?
Context
image.yml,scripts/check_image_versions.py,scripts/bump_image_versions.py, part ofscripts/check_bot_pr_diff.py, their tests, and roughly half ofCLAUDE.md. A contributor has to understand it to bump one tool.From Public design contract replacing the ADR 0004 references: image distribution (pinning by version and digest, a published tag never moved or rebuilt) is an ADR candidate. This ticket decides whether its outcome meets the ADR bar (hard to reverse, surprising, a real trade-off) and, if so, the closing session files the ADR as implementation. ADRs: status
acceptedorsuperseded by NNNN, one screen at most, a residual-risk section only when a risk is accepted, no infrastructure detail.Input from Resolve stale and contradictory claims, decided there; the exact layout is this ticket's:
docs/images/molecule-ubuntu2404.mdandmolecule-ubuntu2604.mddiffer only in the release, thegnupgline, the image variable and the smoke scenario.images/so they are found together (leaning:images/ci/README.mdand oneimages/molecule-ubuntu.md, or wherever a restructured image layout puts them).*.mdunderimages/is excluded inbump_image_versions.py,check_image_versions.py(bump and the docs-exist check) and the Renovate rule description. Thedocumentationlabels point at the new paths (a label edit is an input: bump both molecule images).Resolution
Keep the self-built images; cut the machinery around them. The maintainer weighs CI speed as heavily as simplicity: complexity bought for speed is allowed, but only as a conscious, recorded choice with its measured saving. Each layer was judged on its own.
1. The
ciimage stays, as a recorded speed choice2. Molecule images stay self-built
images/molecule-ubuntu/Dockerfilewith aRELEASEbuild argument; two matrix entries and two image names remain. Condition: Renovate (custom regex manager) keeps tracking both base digests; otherwise keep two files.prepare.ymlinstalls are baked in. Packages the role itself installs stay runtime downloads: that install path is what the test exercises.3. Versions: semver kept, assigned by CI
version:lines leave theimage.ymlmatrix. Onmain, the image job compares the image's inputs (checksum recorded as an image label) with the newest published version and, if they changed, publishes the next patch. A minor or major is a hand edit of a small per-imagebase:line.bump_image_versions.pyand tests,check_image_versions.py bump, the "bump in the same PR" rule, Renovate's post-upgrade task, the bot-diff gate'sversion:exception. A published tag is still never moved.4. The pin follows the build at once
image.ymldispatches the Renovate workflow after it pushes a new version, so the pin PR opens within minutes instead of on the schedule (the last pin PR was opened by hand after the hourly limit ran out; the merge-to-pin gap was 23 min to 6h40m). Whether it automerges is Renovate automerge posture's.5.
check_image_versions.py:pinsmode onlyKeeps the checks that catch real mistakes (job_image release equals the Dockerfile
FROM, label block complete, no production namespace in workflows, the image doc exists), rewritten for the new layout, as small as it goes, each check with a one-line reason.6. Image docs next to the images
images/ci/README.mdand one doc for both molecule images;*.mdunderimages/is not an image input; thedocumentationlabels point at the new paths; the "home lab's LXC hosts" line goes. (Owed from Resolve stale and contradictory claims.)7. Queue and Molecule
cibuild on the single slot.concurrency:group so they never overlap and queue without holding a slot; fallbackflockon the host if this Gitea lacksconcurrency:. The stale-container cleanup only removes containers carrying a Molecule label. The capacity change itself is the maintainer's, in the environment repository.mainruns only the scenarios its diff selects, as a PR does; the nightly full run is the safety net. Residual risk: two PRs that pass alone but break together are caught by the nightly. Recommended setting (maintainer's): require branches to be up to date before merging.8. ADR: yes
Image distribution meets the bar (hard to reverse, surprising, a real trade-off). One ADR: Self-built CI and molecule images, versioned by CI, pinned by version and digest, with the measured saving and the residual risk that an image-input PR is not tested in its own image until the pin PR's CI.
Evidence
Run and job data from 2026-10-24 to 2026-11-15 (Gitea Actions): fast-path Lint jobs 3400, 3456, 3700, 4722, 4732; slow path 4672, 4526; pre-image Lint/Build 2254–2290; full Molecule 3986/4693, 3977, 3974, 3962; queue 3968 (13m42s), 3989; pin PR 153 vs image PRs 146, 148, 151.
ciwent 0.1.0 → 0.2.23 in three weeks (9 versions on Nov 14–15). Not verified: thatactions/cacheworks on this runner; that this Gitea supportsconcurrency:and${{ needs.* }}incontainer.image.Review of the map (2026-11-17).
Partly superseded by Molecule and Renovate on the shared runner: isolation, capacity and cost: one Dockerfile per image, with no release build argument (section 2). Molecule runs are kept apart by per-run isolation, with no shared concurrency group, and Molecule does not run on push to
main(section 7).Section 4's open point is closed by Code-owner approval against Renovate automerge, and where secrets live: the pin-follow pull request waits for one maintainer approval per image build.
Section 8's residual risk ("an image-input PR is not tested in its own image until the pin PR's CI") now also covers an ansible-core bump, which a later decision says is tested by its own pull request. Open in What Molecule proves before a merge, and who acts on the nightly run.