Phase 0 of the Renovate automation. renovate.json is inert until Kamino is added to the Renovate repo list (a later operator step). Nothing here changes image logic or the Collection contents (renovate.json is in build_ignore).
What changes
scripts/bump_image_versions.py: bumps the PATCH version: of exactly the images whose inputs changed in the image.yml matrix; idempotent. Input detection is factored out of check_image_versions.py, whose behaviour is unchanged. A test proves check_image_versions.py bump passes afterwards. Meant as a later Renovate postUpgradeTasks command.
scripts/check_bot_pr_diff.py (PR-only lint.yml step): a renovate/ branch may only change version and pin lines (requirements, hook revs, Dockerfile FROM/uv==, matrix versions, image pins). Added/deleted/mode-changed files fail. It makes bot automerge safe because a bot PR cannot alter workflow logic. The branch name is attacker-controlled, so it only constrains the bot's own PRs.
The pins gate now rejects any git.rkdr.net/defame1297/ reference in the Collection's workflows (the production image set must not appear here).
renovate.json (inert): branch prefix renovate/, semantic commits, minor/patch automerge, majors manual, ansible-core minor/major manual and grouped with ansible-lint, no automerge for the image.yml job container or kaniko, pin-follow for our own images disabled until Phase 4. No postUpgradeTasks.
CLAUDE.md/CONTRIBUTING.md: the two-PR image loop and the bot-diff gate. Dependency and tooling bumps do not change the Collection version; only the operator tags.
Verified
Full tests/scripts run: 101 tests pass. A real ansible-galaxy collection build passes check_tarball.py. renovate-config-validator --strict passes against the CronJob's Renovate version.
Not verified
CI, and the new lint step on a real PR.
Renovate's runtime behaviour (the molecule-image regex match, branch grouping, Gitea platform automerge); the validator checks the schema only.
The pre-commit manager is beta; hooks come from github.com.
requirements-dev.txt still says "Renovate bumps these pins": that file is an input of the ci image, so the wording fix waits for the next real input change.
Phase 0 of the Renovate automation. `renovate.json` is inert until Kamino is added to the Renovate repo list (a later operator step). Nothing here changes image logic or the Collection contents (`renovate.json` is in `build_ignore`).
## What changes
- `scripts/bump_image_versions.py`: bumps the PATCH `version:` of exactly the images whose inputs changed in the `image.yml` matrix; idempotent. Input detection is factored out of `check_image_versions.py`, whose behaviour is unchanged. A test proves `check_image_versions.py bump` passes afterwards. Meant as a later Renovate `postUpgradeTasks` command.
- `scripts/check_bot_pr_diff.py` (PR-only `lint.yml` step): a `renovate/` branch may only change version and pin lines (requirements, hook revs, Dockerfile FROM/`uv==`, matrix versions, image pins). Added/deleted/mode-changed files fail. It makes bot automerge safe because a bot PR cannot alter workflow logic. The branch name is attacker-controlled, so it only constrains the bot's own PRs.
- The `pins` gate now rejects any `git.rkdr.net/defame1297/` reference in the Collection's workflows (the production image set must not appear here).
- `renovate.json` (inert): branch prefix `renovate/`, semantic commits, minor/patch automerge, majors manual, `ansible-core` minor/major manual and grouped with `ansible-lint`, no automerge for the `image.yml` job container or kaniko, pin-follow for our own images disabled until Phase 4. No `postUpgradeTasks`.
- `CLAUDE.md`/`CONTRIBUTING.md`: the two-PR image loop and the bot-diff gate. Dependency and tooling bumps do not change the Collection version; only the operator tags.
## Verified
- Full `tests/scripts` run: 101 tests pass. A real `ansible-galaxy collection build` passes `check_tarball.py`. `renovate-config-validator --strict` passes against the CronJob's Renovate version.
## Not verified
- CI, and the new lint step on a real PR.
- Renovate's runtime behaviour (the molecule-image regex match, branch grouping, Gitea platform automerge); the validator checks the schema only.
- The `pre-commit` manager is beta; hooks come from github.com.
- `requirements-dev.txt` still says "Renovate bumps these pins": that file is an input of the `ci` image, so the wording fix waits for the next real input change.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Factor the changed-path listing and the per-image input detection out of
check_image_versions.py (changed_paths, changed_images) and reuse them in a
new script that bumps the PATCH version of every image whose inputs changed.
It is meant to run later as a Renovate postUpgradeTasks command.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
The pins check now fails when any file under .gitea/workflows mentions
git.rkdr.net/defame1297/, so the environment repo's production images can
never appear in the Collection's CI.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
scripts/check_bot_pr_diff.py fails a pull request from a renovate/ branch
that touches anything but version, tag, digest and image pin lines, so the
automerge of bot pull requests cannot alter workflow logic or reach the org
secrets. Wired as a pull-request-only step of the lint workflow.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
Minor and patch bumps automerge, majors are manual; ansible-core minor and
major, the image.yml job container and kaniko tooling never automerge;
pin-follow for our own images is disabled until Phase 4. No
postUpgradeTasks. renovate.json is in build_ignore, so the Collection archive
is unchanged.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
bump_image_versions.py now locates each matrix.include entry and rewrites the
version: line of the entry whose name: it is, whatever the key order; an entry
it cannot parse unambiguously is a one-line error, and the rewrite is verified
against the YAML before it is written. Files are read and written as UTF-8 with
newline="" so CRLF survives. A shallow clone without a merge-base names the fix
(git fetch --unshallow). check_image_versions.py decodes git's stderr, so errors
no longer print a bytes repr. Untracked files that git ignores were already
skipped; a test now pins that.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
A change git treats as binary (NUL byte, UTF-16, a -diff attribute) or one with
no removed or no added line now fails, and the line diff runs with --text
--no-ext-diff --no-textconv. Tags are limited to [A-Za-z0-9._-]; the digest must
be present on both sides of an ubuntu job container line and of a FROM line;
matrix version lines must stay in place and rise; paths are taken literally
(--literal-pathspecs); an empty head ref on a pull_request fails closed
(EVENT_NAME). The lint workflow runs the guard from origin/main (the whole
scripts/ directory, since it imports check_image_versions) and falls back to
the pull request's copy with a notice while main has none.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
Remove the image-input packageRule that set no option. Add a dockerfile rule that
states, and pins, that base-image tag and digest bumps may automerge (Kamino is
the untrusted side, the pin PR's CI exercises the image); the ubuntu job
container stays at automerge false. Say kaniko is pinned by layer digests that no
manager reads and is updated by hand. List what is not enabled or verified
(GITHUB_COM_TOKEN for the pre-commit manager, main's required checks,
github.head_ref) and that a hand edit on a renovate/ branch stops Renovate's
rebases. renovate-config-validator --strict (renovate 44.161.0) passes.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MmzvM9skAvYcph2c9EiPcm
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.
Phase 0 of the Renovate automation.
renovate.jsonis inert until Kamino is added to the Renovate repo list (a later operator step). Nothing here changes image logic or the Collection contents (renovate.jsonis inbuild_ignore).What changes
scripts/bump_image_versions.py: bumps the PATCHversion:of exactly the images whose inputs changed in theimage.ymlmatrix; idempotent. Input detection is factored out ofcheck_image_versions.py, whose behaviour is unchanged. A test provescheck_image_versions.py bumppasses afterwards. Meant as a later RenovatepostUpgradeTaskscommand.scripts/check_bot_pr_diff.py(PR-onlylint.ymlstep): arenovate/branch may only change version and pin lines (requirements, hook revs, Dockerfile FROM/uv==, matrix versions, image pins). Added/deleted/mode-changed files fail. It makes bot automerge safe because a bot PR cannot alter workflow logic. The branch name is attacker-controlled, so it only constrains the bot's own PRs.pinsgate now rejects anygit.rkdr.net/defame1297/reference in the Collection's workflows (the production image set must not appear here).renovate.json(inert): branch prefixrenovate/, semantic commits, minor/patch automerge, majors manual,ansible-coreminor/major manual and grouped withansible-lint, no automerge for theimage.ymljob container or kaniko, pin-follow for our own images disabled until Phase 4. NopostUpgradeTasks.CLAUDE.md/CONTRIBUTING.md: the two-PR image loop and the bot-diff gate. Dependency and tooling bumps do not change the Collection version; only the operator tags.Verified
tests/scriptsrun: 101 tests pass. A realansible-galaxy collection buildpassescheck_tarball.py.renovate-config-validator --strictpasses against the CronJob's Renovate version.Not verified
pre-commitmanager is beta; hooks come from github.com.requirements-dev.txtstill says "Renovate bumps these pins": that file is an input of theciimage, so the wording fix waits for the next real input change.🤖 Generated with Claude Code