|
1 | 1 | { |
2 | | - $schema: "https://docs.renovatebot.com/renovate-schema.json", |
| 2 | + $schema: 'https://docs.renovatebot.com/renovate-schema.json', |
3 | 3 | extends: [ |
4 | | - "config:recommended", |
5 | | - ":semanticCommitsDisabled", |
6 | | - "regexManagers:githubActionsVersions" |
| 4 | + 'config:recommended', |
| 5 | + ':semanticCommitsDisabled', |
| 6 | + 'customManagers:githubActionsVersions', |
7 | 7 | ], |
8 | | - labels: ["dependencies"], |
9 | | - postUpdateOptions: ["gomodTidy"], |
10 | | - automergeStrategy: "squash", |
| 8 | + labels: ['dependencies'], |
| 9 | + postUpdateOptions: ['gomodTidy'], |
| 10 | + automergeStrategy: 'squash', |
11 | 11 | // required for automerging patch updates |
12 | 12 | separateMinorPatch: true, |
13 | 13 | kubernetes: { |
14 | | - fileMatch: ["\\.yaml$"] |
| 14 | + fileMatch: ['\\.yaml$'], |
15 | 15 | }, |
16 | 16 | customManagers: [ |
17 | 17 | { |
18 | 18 | // generic detection for install manifests from GitHub releases |
19 | | - customType: "regex", |
20 | | - fileMatch: ["kustomization\\.yaml$"], |
21 | | - matchStrings: ["https:\/\/github\\.com\/(?<depName>.*\/.*?)\/releases\/download\/(?<currentValue>.*?)\/"], |
22 | | - datasourceTemplate: "github-releases" |
| 19 | + customType: 'regex', |
| 20 | + fileMatch: ['kustomization\\.yaml$'], |
| 21 | + matchStrings: ['https://github\\.com/(?<depName>.*/.*?)/releases/download/(?<currentValue>.*?)/'], |
| 22 | + datasourceTemplate: 'github-releases', |
23 | 23 | }, |
24 | 24 | { |
25 | 25 | // generic detection for raw manifests from GitHub refs |
26 | | - customType: "regex", |
27 | | - fileMatch: ["kustomization\\.yaml$"], |
28 | | - matchStrings: ["https:\/\/raw.githubusercontent.com\/(?<depName>.*?/.*?)\/(?<currentValue>.*?)\/"], |
29 | | - datasourceTemplate: "github-releases" |
| 26 | + customType: 'regex', |
| 27 | + fileMatch: ['kustomization\\.yaml$'], |
| 28 | + matchStrings: ['https://raw.githubusercontent.com/(?<depName>.*?/.*?)/(?<currentValue>.*?)/'], |
| 29 | + datasourceTemplate: 'github-releases', |
30 | 30 | }, |
31 | 31 | { |
32 | 32 | // update `_VERSION` variables in Makefiles and scripts |
33 | 33 | // inspired by `regexManagers:dockerfileVersions` preset |
34 | | - customType: "regex", |
35 | | - fileMatch: ["Makefile$", "\\.mk$", "\\.sh$"], |
| 34 | + customType: 'regex', |
| 35 | + fileMatch: ['Makefile$', '\\.mk$', '\\.sh$'], |
36 | 36 | matchStrings: [ |
37 | | - "# renovate: datasource=(?<datasource>[a-z-.]+?) depName=(?<depName>[^\\s]+?)(?: (lookupName|packageName)=(?<packageName>[^\\s]+?))?(?: versioning=(?<versioning>[^\\s]+?))?(?: extractVersion=(?<extractVersion>[^\\s]+?))?(?: registryUrl=(?<registryUrl>[^\\s]+?))?\\s.+?_VERSION *[?:]?= *\"?(?<currentValue>.+?)\"?\\s" |
38 | | - ] |
39 | | - } |
| 37 | + '# renovate: datasource=(?<datasource>[a-z-.]+?) depName=(?<depName>[^\\s]+?)(?: (lookupName|packageName)=(?<packageName>[^\\s]+?))?(?: versioning=(?<versioning>[^\\s]+?))?(?: extractVersion=(?<extractVersion>[^\\s]+?))?(?: registryUrl=(?<registryUrl>[^\\s]+?))?\\s.+?_VERSION *[?:]?= *"?(?<currentValue>.+?)"?\\s', |
| 38 | + ], |
| 39 | + }, |
40 | 40 | ], |
41 | 41 | packageRules: [ |
42 | 42 | { |
43 | 43 | // disable update of dependency on the main module |
44 | | - matchPackageNames: ["github.com/timebertt/kubernetes-controller-sharding"], |
45 | | - enabled: false |
| 44 | + matchPackageNames: ['github.com/timebertt/kubernetes-controller-sharding'], |
| 45 | + enabled: false, |
46 | 46 | }, |
47 | 47 | { |
48 | 48 | // automerge non-major updates except 0.* versions |
49 | 49 | // similar to :automergeStableNonMajor preset, but also works for versioning schemes without range support |
50 | | - matchUpdateTypes: ["minor", "patch"], |
51 | | - matchCurrentVersion: "!/^v?0\\./", |
52 | | - automerge: true |
| 50 | + matchUpdateTypes: ['minor', 'patch'], |
| 51 | + matchCurrentVersion: '!/^v?0\\./', |
| 52 | + automerge: true, |
53 | 53 | }, |
54 | 54 | { |
55 | 55 | // automerge patch updates |
56 | | - matchUpdateTypes: ["patch"], |
57 | | - automerge: true |
| 56 | + matchUpdateTypes: ['patch'], |
| 57 | + automerge: true, |
58 | 58 | }, |
59 | 59 | { |
60 | 60 | // disable automerge for go minor updates |
61 | | - matchDatasources: ["golang-version"], |
62 | | - matchUpdateTypes: ["minor"], |
63 | | - automerge: false |
| 61 | + matchDatasources: ['golang-version'], |
| 62 | + matchUpdateTypes: ['minor'], |
| 63 | + automerge: false, |
64 | 64 | }, |
65 | 65 | { |
66 | 66 | // bump k8s and controller-runtime go dependencies together |
67 | | - groupName: "k8s packages", |
68 | | - groupSlug: "k8s-go", |
69 | | - matchDatasources: ["go"], |
70 | | - matchPackagePrefixes: [ |
| 67 | + groupName: 'k8s packages', |
| 68 | + groupSlug: 'k8s-go', |
| 69 | + matchDatasources: ['go'], |
| 70 | + matchPackageNames: [ |
71 | 71 | // from "group:kubernetes" |
72 | | - "k8s.io/api", |
73 | | - "k8s.io/apiextensions-apiserver", |
74 | | - "k8s.io/apimachinery", |
75 | | - "k8s.io/apiserver", |
76 | | - "k8s.io/cli-runtime", |
77 | | - "k8s.io/client-go", |
78 | | - "k8s.io/cloud-provider", |
79 | | - "k8s.io/cluster-bootstrap", |
80 | | - "k8s.io/code-generator", |
81 | | - "k8s.io/component-base", |
82 | | - "k8s.io/controller-manager", |
83 | | - "k8s.io/cri-api", |
84 | | - "k8s.io/csi-translation-lib", |
85 | | - "k8s.io/kube-aggregator", |
86 | | - "k8s.io/kube-controller-manager", |
87 | | - "k8s.io/kube-proxy", |
88 | | - "k8s.io/kube-scheduler", |
89 | | - "k8s.io/kubectl", |
90 | | - "k8s.io/kubelet", |
91 | | - "k8s.io/legacy-cloud-providers", |
92 | | - "k8s.io/metrics", |
93 | | - "k8s.io/mount-utils", |
94 | | - "k8s.io/pod-security-admission", |
95 | | - "k8s.io/sample-apiserver", |
96 | | - "k8s.io/sample-cli-plugin", |
97 | | - "k8s.io/sample-controller", |
| 72 | + 'k8s.io/api**', |
| 73 | + 'k8s.io/apiextensions-apiserver**', |
| 74 | + 'k8s.io/apimachinery**', |
| 75 | + 'k8s.io/apiserver**', |
| 76 | + 'k8s.io/cli-runtime**', |
| 77 | + 'k8s.io/client-go**', |
| 78 | + 'k8s.io/cloud-provider**', |
| 79 | + 'k8s.io/cluster-bootstrap**', |
| 80 | + 'k8s.io/code-generator**', |
| 81 | + 'k8s.io/component-base**', |
| 82 | + 'k8s.io/controller-manager**', |
| 83 | + 'k8s.io/cri-api**', |
| 84 | + 'k8s.io/csi-translation-lib**', |
| 85 | + 'k8s.io/kube-aggregator**', |
| 86 | + 'k8s.io/kube-controller-manager**', |
| 87 | + 'k8s.io/kube-proxy**', |
| 88 | + 'k8s.io/kube-scheduler**', |
| 89 | + 'k8s.io/kubectl**', |
| 90 | + 'k8s.io/kubelet**', |
| 91 | + 'k8s.io/legacy-cloud-providers**', |
| 92 | + 'k8s.io/metrics**', |
| 93 | + 'k8s.io/mount-utils**', |
| 94 | + 'k8s.io/pod-security-admission**', |
| 95 | + 'k8s.io/sample-apiserver**', |
| 96 | + 'k8s.io/sample-cli-plugin**', |
| 97 | + 'k8s.io/sample-controller**', |
98 | 98 | // added packages |
99 | | - "sigs.k8s.io/controller-runtime" |
100 | | - ] |
| 99 | + 'sigs.k8s.io/controller-runtime**', |
| 100 | + ], |
101 | 101 | }, |
102 | 102 | { |
103 | 103 | // disable automerge for k8s minor updates |
104 | | - matchPackagePrefixes: [ |
105 | | - // datasource=go |
106 | | - "k8s.io/", // includes more than the k8s-go group! (e.g., k8s.io/utils) |
107 | | - "sigs.k8s.io/controller-runtime", |
| 104 | + matchPackageNames: [ |
| 105 | + 'k8s.io/**', // includes more than the k8s-go group! (e.g., k8s.io/utils) |
| 106 | + 'sigs.k8s.io/controller-runtime**', |
108 | 107 | // datasource=github-releases |
109 | | - "kubernetes/kubernetes", |
110 | | - "kubernetes-sigs/controller-tools" |
| 108 | + 'kubernetes/kubernetes**', |
| 109 | + 'kubernetes-sigs/controller-tools**', |
111 | 110 | ], |
112 | | - matchUpdateTypes: ["minor"], |
113 | | - automerge: false |
| 111 | + matchUpdateTypes: ['minor'], |
| 112 | + automerge: false, |
114 | 113 | }, |
115 | 114 | { |
116 | 115 | // automerge k8s.io/utils updates |
117 | | - matchDatasources: ["go"], |
118 | | - matchPackageNames: ["k8s.io/utils"], |
119 | | - matchUpdateTypes: ["digest"], |
120 | | - automerge: true |
| 116 | + matchDatasources: ['go'], |
| 117 | + matchPackageNames: ['k8s.io/utils'], |
| 118 | + matchUpdateTypes: ['digest'], |
| 119 | + automerge: true, |
121 | 120 | }, |
122 | 121 | { |
123 | 122 | // setup-envtest is not tagged, don't create a PR for every commit in controller-runtime |
124 | | - matchDatasources: ["go"], |
125 | | - matchPackageNames: ["sigs.k8s.io/controller-runtime/tools/setup-envtest"], |
126 | | - enabled: false |
| 123 | + matchDatasources: ['go'], |
| 124 | + matchPackageNames: ['sigs.k8s.io/controller-runtime/tools/setup-envtest'], |
| 125 | + enabled: false, |
127 | 126 | }, |
128 | 127 | { |
129 | 128 | // jsonpatch has to be kept in sync with k8s and controller-runtime dependencies |
130 | | - matchDatasources: ["go"], |
131 | | - matchPackagePrefixes: ["gomodules.xyz/jsonpatch"], |
132 | | - enabled: false |
| 129 | + matchDatasources: ['go'], |
| 130 | + matchPackageNames: ['gomodules.xyz/jsonpatch**'], |
| 131 | + enabled: false, |
133 | 132 | }, |
134 | 133 | { |
135 | 134 | // kind minor k8s version should be updated together with shoot k8s version |
136 | | - matchPackageNames: ["kindest/node"], |
137 | | - matchUpdateTypes: ["minor"], |
138 | | - enabled: false |
| 135 | + matchPackageNames: ['kindest/node'], |
| 136 | + matchUpdateTypes: ['minor'], |
| 137 | + enabled: false, |
139 | 138 | }, |
140 | 139 | { |
141 | 140 | // combine upgrade of manifests and image tag in one PR |
142 | | - groupName: "external-dns", |
143 | | - matchPackagePatterns: ["external-dns"] |
| 141 | + groupName: 'external-dns', |
| 142 | + matchPackageNames: ['/external-dns/'], |
144 | 143 | }, |
145 | 144 | { |
146 | 145 | // special case for ingress-nginx: version is prefixed with `controller-` |
147 | | - matchDatasources: ["github-releases"], |
148 | | - matchPackageNames: ["kubernetes/ingress-nginx"], |
149 | | - "versionCompatibility": "^(?<compatibility>.*)-(?<version>.+)$" |
| 146 | + matchDatasources: ['github-releases'], |
| 147 | + matchPackageNames: ['kubernetes/ingress-nginx'], |
| 148 | + versionCompatibility: '^(?<compatibility>.*)-(?<version>.+)$', |
150 | 149 | }, |
151 | 150 | { |
152 | 151 | // manual action required: upgrading kube-prometheus is not fully automated yet |
153 | | - matchDatasources: ["github-releases"], |
154 | | - matchPackageNames: ["prometheus-operator/kube-prometheus"], |
155 | | - prHeader: "⚠️ Manual action required ⚠️\nPlease check this PR out and run `hack/config/monitoring/update.sh`." |
| 152 | + matchDatasources: ['github-releases'], |
| 153 | + matchPackageNames: ['prometheus-operator/kube-prometheus'], |
| 154 | + prHeader: '⚠️ Manual action required ⚠️\nPlease check this PR out and run `hack/config/monitoring/update.sh`.', |
156 | 155 | }, |
157 | 156 | { |
158 | 157 | // kube-prometheus manifests are generated and managed by update.sh, disable renovate bumps |
159 | | - matchFileNames: ["hack/config/monitoring/{crds,kube-prometheus}/**"], |
160 | | - enabled: false |
| 158 | + matchFileNames: ['hack/config/monitoring/{crds,kube-prometheus}/**'], |
| 159 | + enabled: false, |
161 | 160 | }, |
162 | 161 | // help renovate fetch changelogs for packages that don't have any sourceUrl metadata attached |
163 | 162 | { |
164 | | - matchPackageNames: ["registry.k8s.io/prometheus-adapter/prometheus-adapter"], |
165 | | - customChangelogUrl: "https://github.com/kubernetes-sigs/prometheus-adapter" |
| 163 | + matchPackageNames: ['registry.k8s.io/prometheus-adapter/prometheus-adapter'], |
| 164 | + changelogUrl: 'https://github.com/kubernetes-sigs/prometheus-adapter', |
166 | 165 | }, |
167 | 166 | { |
168 | | - matchPackageNames: ["registry.k8s.io/kube-state-metrics/kube-state-metrics"], |
169 | | - customChangelogUrl: "https://github.com/kubernetes/kube-state-metrics" |
| 167 | + matchPackageNames: ['registry.k8s.io/kube-state-metrics/kube-state-metrics'], |
| 168 | + changelogUrl: 'https://github.com/kubernetes/kube-state-metrics', |
170 | 169 | }, |
171 | 170 | { |
172 | | - matchPackageNames: ["quay.io/brancz/kube-rbac-proxy"], |
173 | | - customChangelogUrl: "https://github.com/brancz/kube-rbac-proxy" |
174 | | - } |
175 | | - ] |
| 171 | + matchPackageNames: ['quay.io/brancz/kube-rbac-proxy'], |
| 172 | + changelogUrl: 'https://github.com/brancz/kube-rbac-proxy', |
| 173 | + }, |
| 174 | + ], |
176 | 175 | } |
0 commit comments