diff --git a/lib/config/presets/internal/workarounds.ts b/lib/config/presets/internal/workarounds.ts index 53ef59c34a1add2d2a733282986c53b56c85e8f3..8b17b6ccedf3752e71f587855717bc901de2004e 100644 --- a/lib/config/presets/internal/workarounds.ts +++ b/lib/config/presets/internal/workarounds.ts @@ -22,6 +22,7 @@ export const presets: Record<string, Preset> = { 'workarounds:containerbase', 'workarounds:bitnamiDockerImageVersioning', 'workarounds:k3sKubernetesVersioning', + 'workarounds:rke2KubernetesVersioning', ], ignoreDeps: [], // Hack to improve onboarding PR description }, @@ -200,6 +201,17 @@ export const presets: Record<string, Preset> = { }, ], }, + rke2KubernetesVersioning: { + description: 'Use custom regex versioning for rancher/rke2', + packageRules: [ + { + matchDatasources: ['github-releases'], + matchPackageNames: ['rancher/rke2'], + versioning: + 'regex:^v(?<major>\\d+)\\.(?<minor>\\d+)\\.(?<patch>\\d+)(?:-(?<prerelease>[a-z]+\\d+))?(?<compatibility>\\+rke2r)(?<build>\\d+)$', + }, + ], + }, supportRedHatImageVersion: { description: 'Use specific versioning for Red Hat-maintained container images.',