Commit 81da31e
authored
fix(kubeadm): Ensure strict <1.33.0 check for cloud-provider flag (#542)
* fix(test): Switch last-release to v1.6.1 for upgrade test
* fix(release): Update metadata.yaml and Makefile
Add v1.7.99 to Makefile and 1.7 series to metadata.
* fix(deps): update e2e tests to kubernertes v1.32 and CAPI 1.9
* fix(kubeadm): Ensure strict <1.33.0 check for cloud-provider flag
* fix(test): Use kubernetes 1.33 and CAPI 1.10 for e2e
* Update kubernetes-controller-tools to v0.18.0
Update controller-gen and regenerate manifests.
* fix(test): Add required controlPlane field to NutanixFailureDomainConfig in tests
Controller-gen v0.18.0 now properly enforces the +kubebuilder:validation:Required
annotation on the controlPlane field in NutanixFailureDomainConfig. The previous
version (v0.14.0) did not enforce this validation in the generated CRD schema,
but the newer version correctly marks controlPlane as a required field.
This caused unit test panics because test objects were being created without
setting the controlPlane field, which now violates the CRD schema validation.
Fixed by adding ControlPlane: true to all NutanixFailureDomainConfig test objects
in helpers_test.go and nutanixcluster_controller_test.go.
* feat: Upgrade cluster-api dependency to v1.10.3
This commit upgrades cluster-api from v1.8.1 to v1.10.3 to ensure compatibility
with controller-gen v0.18.0. The upgrade required several changes:
1. **Updated dependencies**:
- sigs.k8s.io/cluster-api v1.8.1 → v1.10.3
- sigs.k8s.io/cluster-api/test v1.8.1 → v1.10.3
- Updated many transitive dependencies
2. **Fixed RateLimiter type compatibility**:
- Updated ControllerConfig to use workqueue.TypedRateLimiter[reconcile.Request]
- Fixed predicate function calls to include scheme parameter
- Updated test cases to use typed rate limiters
3. **Addressed breaking changes**:
- Fixed predicates.ClusterUnpausedAndInfrastructureReady() calls
- Removed deprecated MetricsBindAddr field usage in tests
- Updated main.go rate limiter configurations
This upgrade resolves the e2e test failures that were occurring with the
controller-gen v0.18.0 upgrade by ensuring all dependencies are compatible.
* fix(deps): upgrade cluster-api/test to v1.10.3
* fix(manifests): regenerate manifests
* fix(test): set clusterproxy in helpers
* fix(lint): gofumpt
* fix(deps): remove dependency on cluster-api/errors pkg
package is deprecated and will be removed in future.
* fix(manifests): config/manager/kustomization.yaml
* fix(controller): add named controllers and skip uniqueness validation
* fix(test): update test helpers
* fix(refactor): use a const to denote CreateError
* fix(test): use 1 version older kubernetes for clusterctl upgrade
CAPX 1.6.1 can't create 1.33 cluster so we use kubernetes v1.32
for clusterctl upgrade test. this is temporary workaround to fix
the broken CI until we release CAPX 1.7.0 and update the test to
use 1.7.0 instead of 1.6.1.
* fix(controller): Skip unique controller name validation in unit tests1 parent c82fed7 commit 81da31e
File tree
40 files changed
+614
-559
lines changed- api/v1beta1
- config
- crd/bases
- rbac
- controllers
- pkg/context
- templates
- base
- test/e2e
- config
40 files changed
+614
-559
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
28 | 27 | | |
29 | 28 | | |
30 | 29 | | |
| |||
98 | 97 | | |
99 | 98 | | |
100 | 99 | | |
101 | | - | |
| 100 | + | |
102 | 101 | | |
103 | 102 | | |
104 | 103 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
25 | 24 | | |
26 | 25 | | |
27 | 26 | | |
| |||
271 | 270 | | |
272 | 271 | | |
273 | 272 | | |
274 | | - | |
| 273 | + | |
275 | 274 | | |
276 | 275 | | |
277 | 276 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| |||
Lines changed: 21 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
65 | | - | |
| 65 | + | |
| 66 | + | |
66 | 67 | | |
67 | 68 | | |
68 | | - | |
| 69 | + | |
69 | 70 | | |
70 | 71 | | |
71 | 72 | | |
| |||
88 | 89 | | |
89 | 90 | | |
90 | 91 | | |
91 | | - | |
92 | 92 | | |
93 | | - | |
94 | 93 | | |
95 | 94 | | |
96 | 95 | | |
| |||
104 | 103 | | |
105 | 104 | | |
106 | 105 | | |
107 | | - | |
108 | 106 | | |
109 | 107 | | |
110 | 108 | | |
111 | 109 | | |
112 | 110 | | |
113 | | - | |
114 | 111 | | |
115 | 112 | | |
116 | 113 | | |
| |||
179 | 176 | | |
180 | 177 | | |
181 | 178 | | |
| 179 | + | |
182 | 180 | | |
183 | 181 | | |
184 | 182 | | |
| |||
270 | 268 | | |
271 | 269 | | |
272 | 270 | | |
273 | | - | |
| 271 | + | |
274 | 272 | | |
275 | 273 | | |
276 | 274 | | |
277 | 275 | | |
278 | 276 | | |
279 | 277 | | |
280 | | - | |
| 278 | + | |
281 | 279 | | |
| 280 | + | |
| 281 | + | |
282 | 282 | | |
283 | 283 | | |
284 | 284 | | |
285 | | - | |
| 285 | + | |
286 | 286 | | |
287 | | - | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
288 | 290 | | |
289 | 291 | | |
290 | 292 | | |
291 | | - | |
| 293 | + | |
292 | 294 | | |
293 | 295 | | |
| 296 | + | |
294 | 297 | | |
295 | 298 | | |
296 | | - | |
| 299 | + | |
297 | 300 | | |
298 | 301 | | |
299 | 302 | | |
300 | | - | |
| 303 | + | |
301 | 304 | | |
302 | 305 | | |
| 306 | + | |
| 307 | + | |
303 | 308 | | |
304 | 309 | | |
305 | 310 | | |
| |||
316 | 321 | | |
317 | 322 | | |
318 | 323 | | |
319 | | - | |
| 324 | + | |
320 | 325 | | |
321 | 326 | | |
322 | 327 | | |
323 | | - | |
| 328 | + | |
324 | 329 | | |
325 | 330 | | |
326 | 331 | | |
| |||
Lines changed: 7 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
59 | 61 | | |
60 | 62 | | |
61 | | - | |
| 63 | + | |
| 64 | + | |
62 | 65 | | |
63 | 66 | | |
64 | 67 | | |
| |||
81 | 84 | | |
82 | 85 | | |
83 | 86 | | |
84 | | - | |
85 | 87 | | |
86 | | - | |
87 | 88 | | |
88 | 89 | | |
89 | 90 | | |
| |||
97 | 98 | | |
98 | 99 | | |
99 | 100 | | |
100 | | - | |
101 | 101 | | |
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
105 | 105 | | |
106 | | - | |
107 | 106 | | |
108 | 107 | | |
109 | 108 | | |
| |||
176 | 175 | | |
177 | 176 | | |
178 | 177 | | |
| 178 | + | |
179 | 179 | | |
180 | 180 | | |
181 | 181 | | |
| |||
Lines changed: 15 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
114 | | - | |
| 114 | + | |
115 | 115 | | |
116 | 116 | | |
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
120 | 120 | | |
121 | | - | |
| 121 | + | |
122 | 122 | | |
| 123 | + | |
| 124 | + | |
123 | 125 | | |
124 | 126 | | |
125 | 127 | | |
126 | | - | |
| 128 | + | |
127 | 129 | | |
128 | | - | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
129 | 133 | | |
130 | 134 | | |
131 | 135 | | |
132 | | - | |
| 136 | + | |
133 | 137 | | |
134 | 138 | | |
| 139 | + | |
135 | 140 | | |
136 | 141 | | |
137 | | - | |
| 142 | + | |
138 | 143 | | |
139 | 144 | | |
140 | 145 | | |
141 | | - | |
| 146 | + | |
142 | 147 | | |
143 | 148 | | |
| 149 | + | |
| 150 | + | |
144 | 151 | | |
145 | 152 | | |
146 | 153 | | |
| |||
0 commit comments