Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

renovate: add workflow to validate config #784

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

roobre
Copy link
Collaborator

@roobre roobre commented Jul 8, 2024

Since we don't use neither the dependency dashboard, nor the SaaS renovate, it may become hard to know if we introduce modifications to the renovate config that do not make sense.

This PR adds a simple check that runs the renovate-config-validator tool to ensure the config is valid.

@roobre roobre force-pushed the renovate-validate branch 3 times, most recently from 5d06808 to a4835ee Compare July 8, 2024 12:46
@roobre roobre marked this pull request as ready for review July 8, 2024 12:47
@roobre roobre requested a review from a team as a code owner July 8, 2024 12:47
.github/workflows/renovate-validate.yaml Outdated Show resolved Hide resolved
- name: Checkout Code
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
- run: |-
docker run -i --rm -v $(realpath .):/repo -w /repo --entrypoint renovate-config-validator ghcr.io/renovatebot/renovate --strict
Copy link
Contributor

Choose a reason for hiding this comment

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

oh, run, we are validating an old renovate configuration file with a new renovate version.

Doesn't this work with the github action?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I could argue that validating with latest is a feature!

Doesn't this work with the github action?

The truth is that I assumed no and didn't check, but it might be possible after all!
https://github.com/renovatebot/github-action/blob/044641a5b884facaf733f679cc57474321fa039d/action.yml#L39

Let me check real quick.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It doesn't seem possible sadly :(

The docker-cmd-file is automatically mounted and basenamed:
https://github.com/renovatebot/github-action/blob/044641a5b884facaf733f679cc57474321fa039d/src/renovate.ts#L42-L49

I can see your concern of these getting out of sync though. I can add a regex to #768 so renovate updates both things (action and this image) it that looks good to you.

Copy link
Contributor

Choose a reason for hiding this comment

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

sure!

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@mem Any other thoughts? I can make the change we were discussing here in #768 if that's fine by you 😊

@roobre roobre requested a review from mem July 9, 2024 12:18
@roobre roobre force-pushed the renovate-validate branch 3 times, most recently from 61eb477 to 4cd3097 Compare July 10, 2024 09:17
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.

2 participants