Updating dependencies with Renovate
The Cilium project uses Renovate Bot to maintain and update dependencies on a regular basis. This guide describes how to contribute a PR which modifies the Renovate configuration. There are two complementary methods for validating Renovate changes: Linting with the “local” platform, and testing the updates in your own fork.
renovate/renovate docker image to perform a dry run of Renovate.
This step should complete in less than ten minutes, and it will report syntax
errors in the configuration.
Make some changes to the Renovate configuration in
Run the renovate image against the new configuration.
docker run -ti -e LOG_LEVEL=debug \ -e GITHUB_COM_TOKEN="$(gh auth token)" \ -v /tmp:/tmp \ -v $(pwd):/usr/src/app \ docker.io/renovate/renovate:full \ renovate --platform=local \ | tee renovate.log
This approach is based on the Local platform guide provided by Renovate. See that guide for more details about usage and limitations.
Testing on a fork
For most changes to the Renovate configuration, you will likely need to test the changes on your own fork of Cilium.
Make some changes to the Renovate configuration. Renovate is configured in
(Optional) Disable unrelated configuration. For an example, see this commit.
Push the branch to the default branch of your own fork.
Enable the Renovate GitHub app in your GitHub account.
Ensure that Renovate is enabled in the repository settings in the Renovate Dashboard.
Trigger the Renovate app from the dashboard or push a fresh commit to your fork’s default branch to trigger Renovate again.
Use the dashboard to trigger Renovate to create a PR on your fork and validate that the proposed PRs are updating the correct parts of the codebase.
Once you have tested that the Renovate configuration works in your own fork, create a PR against Cilium and provide links in the description to inform reviewers about the testing you have performed on the changes.