Skip to content

chore(ci): enable weekly flake.lock maintenance for nix manager - #1087

Merged
jbw976 merged 2 commits into
crossplane:mainfrom
pujitha24:auto/issue-1086
Jul 31, 2026
Merged

chore(ci): enable weekly flake.lock maintenance for nix manager#1087
jbw976 merged 2 commits into
crossplane:mainfrom
pujitha24:auto/issue-1086

Conversation

@pujitha24

@pujitha24 pujitha24 commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Motivation:

Our Go toolchain comes from the nixpkgs-unstable flake input, which is
pinned by a branch ref rather than a version. Renovate's nix manager
tracks this input, but a branch ref never shows a newer version to bump
to, so Renovate never proposes updating flake.lock. As a result the
locked revision - and therefore our Go version - never advances; we
have been stuck on Go 1.25.9 while 1.25.12 is current.

Approach:

Enable Renovate's lockFileMaintenance for the nix manager, which runs
nix flake update on a schedule regardless of whether Renovate detects
a version bump. This is the mechanism that actually moves branch-ref
inputs like nixpkgs-unstable forward. Also switch the cadence from
monthly to weekly, since we still depend on upstream nixpkgs picking up
new Go releases first and want to pick up those updates faster once it
does. This mirrors the lockFileMaintenance configuration already in use
in crossplane/crossplane's .github/renovate-nix.json5.

This is a Renovate/CI automation config change only; it does not alter
any runtime code or user-facing behavior. It changes how often and
under what conditions our automated dependency-update bot opens a PR
to bump flake.lock.

Validation:

Ran this repo's own CI validation checks for Renovate presets locally:

npx --yes json5 .github/renovate-nix.json5
npx --yes --package renovate -- renovate-config-validator

Both passed ("Config validated successfully").

Related to #1086

Signed-off-by: Pujitha Paladugu 10557236+pujitha24@users.noreply.github.com

Motivation:

Our Go toolchain comes from the nixpkgs-unstable flake input, which is
pinned by a branch ref rather than a version. Renovate's nix manager
tracks this input, but a branch ref never shows a newer version to bump
to, so Renovate never proposes updating flake.lock. As a result the
locked revision - and therefore our Go version - never advances; we
have been stuck on Go 1.25.9 while 1.25.12 is current.

Approach:

Enable Renovate's lockFileMaintenance for the nix manager, which runs
`nix flake update` on a schedule regardless of whether Renovate detects
a version bump. This is the mechanism that actually moves branch-ref
inputs like nixpkgs-unstable forward. Also switch the cadence from
monthly to weekly, since we still depend on upstream nixpkgs picking up
new Go releases first and want to pick up those updates faster once it
does. This mirrors the lockFileMaintenance configuration already in use
in crossplane/crossplane's .github/renovate-nix.json5.

This is a Renovate/CI automation config change only; it does not alter
any runtime code or user-facing behavior. It changes how often and
under what conditions our automated dependency-update bot opens a PR
to bump flake.lock.

Validation:

Ran this repo's own CI validation checks for Renovate presets locally:

  npx --yes json5 .github/renovate-nix.json5
  npx --yes --package renovate -- renovate-config-validator

Both passed ("Config validated successfully").

Fixes crossplane#1086

Signed-off-by: Pujitha Paladugu <10557236+pujitha24@users.noreply.github.com>
@pujitha24
pujitha24 requested a review from a team as a code owner July 29, 2026 16:34
@pujitha24
pujitha24 requested review from Copilot and haarchri July 29, 2026 16:34

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@jbw976 jbw976 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

awesome @pujitha24, thanks for taking this on so quickly! i was also working on a fix last night that updates a couple other config settings, so to stay fair and keep your credit for contribution here, i'll just push my additional settings as an extra commit to this branch/PR, unless you have major objections to that 😇

@pujitha24

Copy link
Copy Markdown
Contributor Author

Thanks @jbw976! No objections at all — happy for you to push your additional config settings as an extra commit on this branch. Let me know if there's anything else you'd like adjusted here.

…nches

schedule:weekly resolves to "* 0-3 * * 1", a window of 00:00 to 03:59 UTC on
Monday. Our Renovate workflow's cron fires at 08:00 UTC, and GitHub only
delays scheduled runs rather than advancing them, so our job will never hit
that window. A literal 'on monday' covers the whole day, so it stays reachable
however late the run starts.

The blanket release-branch opt-out in the base config also suppressed the
refresh on release-2.2 and newer. Those branches build with nix and pin the
Go toolchain in flake.lock the same way main does, so a rule re-enables lock
file maintenance for them. release-2.1 and older use Earthly and have no
flake.lock, so they stay excluded.

While we're at it, bump the prConcurrentLimit back up to Renovate's default of
10, so we get more throughput when there's a backlog.

Signed-off-by: Jared Watts <jbw976@gmail.com>
@jbw976

jbw976 commented Jul 31, 2026

Copy link
Copy Markdown
Member

Awesome, thanks for the collaboration @pujitha24! 🙌

I pushed 3982028, so now this PR has both of our commits, to add a couple more settings:

  • set the schedule to on monday so our renovate workflow cron config will be compatible with renovate's odd definition of "weekly" 😂
  • allow this lock file maintenance to happen on release branches as well, so we don't miss Go version bumps there
  • bump up the concurrent PR limit to get more throughput again when there's a backlog

@pujitha24

Copy link
Copy Markdown
Contributor Author

Thanks for the fixes, @jbw976! The on monday schedule fix, release-branch coverage, and prConcurrentLimit bump all make sense to me — appreciate you catching the schedule:weekly reachability issue, I wouldn't have caught that. I re-ran the repo's renovate config validation locally with both commits in place and it still passes cleanly. Nothing further from my side — this looks ready whenever you are.

@jbw976
jbw976 merged commit a35ad16 into crossplane:main Jul 31, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants