kustomize, regex versioning not detected, registryUrls ignored #7950
Replies: 22 comments
-
|
Beta Was this translation helpful? Give feedback.
-
I am not sure if I follow:
right? No way how to group packages per registry ? |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
https://docs.renovatebot.com/presets-docker/#dockerenablemajor is how to enable major updates for docker. |
Beta Was this translation helpful? Give feedback.
-
You can use the following to additionally match packages in rules. https://docs.renovatebot.com/configuration-options/#packagepatterns https://docs.renovatebot.com/configuration-options/#sourceurlprefixes |
Beta Was this translation helpful? Give feedback.
-
to get renovate working on kustomize you need to add renovate/lib/manager/kustomize/extract.ts Line 74 in 3b1ed2f see viceice-tests/kustomization#1 for sample |
Beta Was this translation helpful? Give feedback.
-
So i suggest the following config for you {
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": ["config:base", ":dependencyDashboard"],
"prHourlyLimit": 60,
"prConcurrentLimit": 10,
"packageRules": [
{
"packagePatterns": [
"^example\\.com\\/foo\\/hello-world"
],
"groupName": "some-group"
}
]
} Remove the packagerout, if you don't want to group. Also the dependency dashboard is very helpful, sample is here and here |
Beta Was this translation helpful? Give feedback.
-
Thanks ! ❤️ Works for me:
Actually I had |
Beta Was this translation helpful? Give feedback.
-
Please use: {
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": ["config:base", ":dependencyDashboard"],
"prHourlyLimit": 60,
"prConcurrentLimit": 10
} |
Beta Was this translation helpful? Give feedback.
-
I don't understand how it's working with updateTypes in that package rule |
Beta Was this translation helpful? Give feedback.
-
Me neither, I am aware of docker versioning, but I want to bumping explicitly over |
Beta Was this translation helpful? Give feedback.
-
You would need to do it this way then:
First rule is to apply the versioning to those package names. Second rule is for after lookup and versioning has been done, to then enable major updates. |
Beta Was this translation helpful? Give feedback.
-
^ Problem is that package example.com/foo/hello-world is detected as "manager": "kustomize", "datasource": "docker" and "versioning": "docker", so regex vesioning is not applied, thats why major updates are working, its in log in OP. Not sure whats wrong, even:
nor
rules are not working.. EDIT:
|
Beta Was this translation helpful? Give feedback.
-
@rarkins its not possible to switch versioning in kustomize manager, isnt it hardcoded somehow ? |
Beta Was this translation helpful? Give feedback.
-
@lukasmrtvy can you please provide a public reproduction repo. Please also describe again what pr you expect and what pr you wrongly get. I've provided a minimal repo, which does what you want above, so it's not clear what you are expecting. |
Beta Was this translation helpful? Give feedback.
-
As You can see here https://gitlab.com/lukasmrtvy/kustomization-renovate/-/jobs/894051757, its not possible to set regex versioning for docker images in kustomize manager, even with @rarkins snippet. ( .. and I dont want to use loose/docker versioning.. )
https://github.com/renovatebot/config-help/issues/1013 ( remote bases problem ) is solved ( workaround ) by https://github.com/renovatebot/config-help/issues/1013#issuecomment-738707195 |
Beta Was this translation helpful? Give feedback.
-
Ok, not sure why versioning isn't working, will try to debug. What is the problem to not using |
Beta Was this translation helpful? Give feedback.
-
@viceice I have to use regex for more complex use case, also I want to use maven versioning for other environemnts ( other than dev env ) and this will definetly will not work cuz of some strange bug in kustomize.. |
Beta Was this translation helpful? Give feedback.
-
ok, docker versioning is assigned here I think the regex versioning will be applied, but the log will show the extracted deps without applied package rules, so you need to make your sample some more complex to see the diffenrences between docker and regex versioning. So maybe your regex is simply wrong and doesn't match what you expect. |
Beta Was this translation helpful? Give feedback.
-
I switched versioning to loose https://gitlab.com/lukasmrtvy/kustomization-overlay/-/blob/6c89898a0c7fc8c87221db350ab862f56e5e576e/renovate.json#L11, |
Beta Was this translation helpful? Give feedback.
-
It is using loose versioning because docker versioning won't suggest to update from BTW: please remove this line, no longer needed and can cause issues. |
Beta Was this translation helpful? Give feedback.
-
Oh, that makes debugging very hard. Would be nice to log actual versioning used for packageRule. This is really confusing, but again, I am newbie ( Iack of knowledge regarding renovate ). Thanks ! ❤️ P.S. I removed that line. For example instead of this:
use:
|
Beta Was this translation helpful? Give feedback.
-
Which Renovate are you using?
Renovate Open Source CLI
Which platform are you using?
GitLab self-hosted
Have you checked the logs? Don't forget to include them if relevant
What would you like to do?
I am trying to bumping major version (
<number>-rolling
) in kustomize manager via package rule, but:registryUrls
andpackageNames
together ( its possible to useexample.com/foo/hello-world
as packageName, but its quite redundant if packageNames > 1 )renovate.json
foo/hello-world/kustomization.yaml
Thanks for help. I am not sure if I am hitting multiple bugs or its just wrong config. But kustomize manager is not so well tested #7783
Beta Was this translation helpful? Give feedback.
All reactions