fix: disable Renovate Dockerfile base-image updates in downstream repos#365
Open
coretl wants to merge 1 commit into
Open
fix: disable Renovate Dockerfile base-image updates in downstream repos#365coretl wants to merge 1 commit into
coretl wants to merge 1 commit into
Conversation
Downstream repos generated from this template were getting Renovate PRs (e.g. "Update ubuntu Docker tag") for base images that are only ever meant to be bumped centrally, in template/Dockerfile.jinja. Add a packageRule to renovate.json.jinja that disables the dockerfile manager for ubuntu and ghcr.io/diamondlightsource/ubuntu-devcontainer, mirroring the existing pyenv and github-actions disable rules. Reported in bluesky/scanspec#211.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Downstream repos generated from this template were receiving Renovate PRs (e.g. "Update ubuntu Docker tag") for Docker base images that are only ever meant to be bumped centrally, in
template/Dockerfile.jinja. This PR adds apackageRuletotemplate/renovate.json.jinja— the config shipped to downstream projects — that disables Renovate'sdockerfilemanager for the two template-managed base images (ubuntuandghcr.io/diamondlightsource/ubuntu-devcontainer), mirroring the existing rules that already disablepyenvand template-managed GitHub Actions.The rule is appended to the end of the
packageRulesarray (not inserted before the existing github-actions rule), sincetests/test_example.py::test_renovate_actions_match_what_is_shippedhard-indexespackageRules[1]as the github-actions rule.Originating request
From a maintainer comment on bluesky/scanspec#211: Renovate was opening Docker base-image bump PRs in downstream repos, but those base images are managed centrally by this template — the update should only ever happen here, not downstream.
Deliberately left alone
renovate.json(this template repo's own Renovate config) was not changed — this repo should keep receiving Docker base-image updates itself, since it's the one place those bumps are supposed to land.template/Dockerfile.jinja, the rootDockerfile, workflows, anduv.lockwere not touched.Verification
Ran locally from the repo root, as CI does:
uv run --locked tox -e pre-commit— passed.uv run --locked tox -e tests—test_renovate_actions_match_what_is_shippedpasses for all 5 parametrized scenarios (no-docker, docker, docker+debug, pypi, sphinx docs). Two pre-existing, unrelated failures were confirmed to reproduce identically on unmodifiedmain(a docs-build test blocked by network/proxy restrictions in this sandbox, and a template-version-hash mismatch in a generated doc link) — left untouched as instructed.🤖 Generated with Claude Code
Generated by Claude Code