docs(adr): record self-built CI and molecule images, versioned by CI, pinned by version and digest #404

Merged
Defame1297 merged 4 commits from docs/167-image-adr into main 2026-11-26 21:45:57 +00:00
Owner

What and why

Closes #167

  • docs/adr/0002-self-built-ci-and-molecule-images.md, status accepted on approval of this pull request:
    • The decision: own ci image and one Dockerfile per molecule image; molecule images bake in everything except what a role installs; consumers pin <version>@sha256:<digest>; CI assigns the patch version and never moves a tag; Renovate moves the pin after each build; Molecule runs are isolated per run and do not run on push to main.
    • The reason: the measured saving (Lint 82s → 33s, Build 50s → 13s, each with its dates) and the cost (about 4 min per ci build, 0.1.0 → 0.2.23 in three weeks).
  • SECURITY.md: two new entries in Accepted risks, "No Molecule run after a merge" and "Pin bumps first behaviour-tested after they merge". The ADR links to them.

Deviation from the issue body. #167 says to keep the residual risk in the ADR. docs/adr/AGENTS.md was committed after that text and says "An accepted risk is an entry in the 'Accepted risks' section of SECURITY.md … not an amendment to an ADR". ADR 0001 and the Notes of map #87 say the same. So the two residual-risk items are register entries, with the issue's wording kept. The issue's last comment left this choice to the maintainer.

Known gap in the tree. The molecule images still preinstall the role packages and say "a converge makes no network calls". The ADR records the decision; #170 removes the packages.

No changelog fragment: nothing changes for consumers.

Verified

  • pre-commit run --all-files: passed, including REUSE, gitleaks, the Conventional Commit check and the Assisted-by trailer check.
  • Pre-push ansible-test sanity: passed.
  • Two independent review rounds by subagents, one on standards and one on the spec. Findings fixed: each measurement now has its date, the "Not done" section gives the recorded Dockerfile reason, a term undefined in SECURITY.md is replaced, and a claim that had no date is dated.
  • Claims checked against the tree:
    • molecule.yml has no push trigger and isolates each run with KAMINO_RUN_ID names and labels.
    • run_molecule_in_ci_image.sh compares the pull request's pin files with /opt/ci-pins.sha256.
    • next_image_version.py assigns the version, and Renovate's workflow_run opens the pin pull request.
  • Links resolve. The ADR is 49 lines (0001 is 74). It names no hosts, sizing or secrets.

Not verified

  • Molecule and CI behaviour: this change is documentation only.
  • The measured figures come from the decision tickets (#96, #212). They were not measured again here.

  • I confirm third-party material is recorded in NOTICE and REUSE.toml, or there is none.

Assisted-by: Claude Code

## What and why Closes #167 - **`docs/adr/0002-self-built-ci-and-molecule-images.md`**, status `accepted` on approval of this pull request: - The decision: own `ci` image and one Dockerfile per molecule image; molecule images bake in everything except what a role installs; consumers pin `<version>@sha256:<digest>`; CI assigns the patch version and never moves a tag; Renovate moves the pin after each build; Molecule runs are isolated per run and do not run on push to `main`. - The reason: the measured saving (Lint 82s → 33s, Build 50s → 13s, each with its dates) and the cost (about 4 min per `ci` build, 0.1.0 → 0.2.23 in three weeks). - **`SECURITY.md`**: two new entries in Accepted risks, "No Molecule run after a merge" and "Pin bumps first behaviour-tested after they merge". The ADR links to them. **Deviation from the issue body.** #167 says to keep the residual risk in the ADR. `docs/adr/AGENTS.md` was committed after that text and says "An accepted risk is an entry in the 'Accepted risks' section of SECURITY.md … not an amendment to an ADR". ADR 0001 and the Notes of map #87 say the same. So the two residual-risk items are register entries, with the issue's wording kept. The issue's last comment left this choice to the maintainer. **Known gap in the tree.** The molecule images still preinstall the role packages and say "a converge makes no network calls". The ADR records the decision; #170 removes the packages. No changelog fragment: nothing changes for consumers. ## Verified - `pre-commit run --all-files`: passed, including REUSE, gitleaks, the Conventional Commit check and the `Assisted-by` trailer check. - Pre-push `ansible-test sanity`: passed. - Two independent review rounds by subagents, one on standards and one on the spec. Findings fixed: each measurement now has its date, the "Not done" section gives the recorded Dockerfile reason, a term undefined in `SECURITY.md` is replaced, and a claim that had no date is dated. - Claims checked against the tree: - `molecule.yml` has no push trigger and isolates each run with `KAMINO_RUN_ID` names and labels. - `run_molecule_in_ci_image.sh` compares the pull request's pin files with `/opt/ci-pins.sha256`. - `next_image_version.py` assigns the version, and Renovate's `workflow_run` opens the pin pull request. - Links resolve. The ADR is 49 lines (0001 is 74). It names no hosts, sizing or secrets. ## Not verified - Molecule and CI behaviour: this change is documentation only. - The measured figures come from the decision tickets (#96, #212). They were not measured again here. --- - [x] I confirm third-party material is recorded in `NOTICE` and `REUSE.toml`, or there is none. Assisted-by: Claude Code
Claude added this to the Continuous delivery milestone 2026-11-26 21:28:48 +00:00
Claude added 3 commits 2026-11-26 21:28:49 +00:00
ADR 0002 records the decision with its measured saving and build cost.
The two risks it leaves (no Molecule run after a merge, and pin bumps
first behaviour-tested after they merge) go to the Accepted risks
register in SECURITY.md, as docs/adr/AGENTS.md requires.

Closes #167

Assisted-by: Claude Code
Assisted-by: Claude Code
docs(security): date the no-failure evidence of the post-merge entry
Build / build (pull_request) Successful in 28s
Molecule / molecule (pull_request) Successful in 9s
Lint / lint (pull_request) Successful in 1m56s
87280a2f60
Assisted-by: Claude Code
CODEOWNERS rules requested review from Defame1297 2026-11-26 21:28:49 +00:00
Defame1297 added 1 commit 2026-11-26 21:41:17 +00:00
Merge branch 'main' into docs/167-image-adr
Build / build (pull_request) Successful in 1m3s
Molecule / molecule (pull_request) Successful in 6s
Lint / lint (pull_request) Successful in 3m26s
e3d5c35fcd
Defame1297 approved these changes 2026-11-26 21:41:40 +00:00
Defame1297 scheduled this pull request to auto merge when all checks succeed 2026-11-26 21:41:44 +00:00
Defame1297 merged commit 1afce962a0 into main 2026-11-26 21:45:57 +00:00
Defame1297 deleted branch docs/167-image-adr 2026-11-26 21:46:01 +00:00
Sign in to join this conversation.
No Reviewers
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mortis/Kamino#404