Skip to content

Merge https://github.com/kubernetes-sigs/cluster-api:v1.13.2 (ebd807c) into main#298

Open
cloud-team-rebase-bot[bot] wants to merge 623 commits into
openshift:mainfrom
openshift-cloud-team:rebase-bot-main
Open

Merge https://github.com/kubernetes-sigs/cluster-api:v1.13.2 (ebd807c) into main#298
cloud-team-rebase-bot[bot] wants to merge 623 commits into
openshift:mainfrom
openshift-cloud-team:rebase-bot-main

Conversation

@cloud-team-rebase-bot
Copy link
Copy Markdown

@cloud-team-rebase-bot cloud-team-rebase-bot Bot commented May 25, 2026

Summary by CodeRabbit

  • New Features

    • Added encryption algorithm configuration support for kubeadm bootstrap.
    • Added machine taint management capabilities in topology configuration.
    • Enhanced disk layout and partition configuration options.
    • Added machine failure domain tracking in status.
  • Improvements

    • Improved machine health checks with condition-based detection.
    • Enhanced build system with additional verification targets.
    • Updated API versions and removed deprecated admission review versions.
  • Removals

    • Removed deprecated CRD storage version migration option.
    • Removed deprecated --disable-grouping flag from describe command.

k8s-ci-robot and others added 30 commits March 3, 2026 11:44
…bot/go_modules/all-go-mod-patch-and-minor-2fc94a814f

🌱 Bump the all-go-mod-patch-and-minor group across 3 directories with 8 updates
…es-status-addresses-even-further

🌱  api: relax validation for Machine .status.addresses to maximum of 256 instead of 128 items
* Postpone date when we stop serving v1beta1

* Address comments
Signed-off-by: Stefan Büringer buringerst@vmware.com
* Add rolloutAfter to cluster.spec.topology

* Address comments
…eout-unset

🌱 Avoid unsetting nodeDeletionTimeoutSeconds during Machine deletion
apiserver

Signed-off-by: Stefan Büringer buringerst@vmware.com
Signed-off-by: Stefan Büringer buringerst@vmware.com
…per-no-up-safeguard

🌱 Add safeguard to patchHelper to avoid sending empty patches to the apiserver
…utafter-uptodate

🐛 Fix UpToDate calculation for rolloutAfter
- Stop streaming when pod or container has terminated, but ensure
  we stream the logs at least once.
- Add containerHasTerminated helper with tests.

The current behavior is to try again every 2 seconds for terminated
containers. This becomes silly for init containers particularly, since
we fetch the logs from the beginning for each retry so that we end up
with logs repeated again and again.

Signed-off-by: Lennart Jern <lennart.jern@est.tech>
Signed-off-by: Stefan Büringer buringerst@vmware.com
Signed-off-by: Stefan Büringer buringerst@vmware.com
…helper-flake

🐛 Fix patchHelper unit test flakes
Signed-off-by: Stefan Büringer buringerst@vmware.com
…he-optimization

✨ Optimize cache configuration of CABPK & standardize cache/client setup
… 1 update

Bumps the all-go-mod-patch-and-minor group with 1 update in the / directory: [sigs.k8s.io/controller-runtime](https://github.com/kubernetes-sigs/controller-runtime).
Bumps the all-go-mod-patch-and-minor group with 1 update in the /hack/tools directory: [sigs.k8s.io/controller-runtime](https://github.com/kubernetes-sigs/controller-runtime).
Bumps the all-go-mod-patch-and-minor group with 1 update in the /test directory: [sigs.k8s.io/controller-runtime](https://github.com/kubernetes-sigs/controller-runtime).


Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

Updates `sigs.k8s.io/controller-runtime` from 0.23.1 to 0.23.3
- [Release notes](https://github.com/kubernetes-sigs/controller-runtime/releases)
- [Changelog](https://github.com/kubernetes-sigs/controller-runtime/blob/main/RELEASE.md)
- [Commits](kubernetes-sigs/controller-runtime@v0.23.1...v0.23.3)

---
updated-dependencies:
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
- dependency-name: sigs.k8s.io/controller-runtime
  dependency-version: 0.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: all-go-mod-patch-and-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
…bot/go_modules/all-go-mod-patch-and-minor-f488d51061

🌱 Bump the all-go-mod-patch-and-minor group across 3 directories with 1 update
I should've just read the CAEP better, but this confounded me for a good few hours.

Clarify that ClusterResourceSet is namespace-scoped and requires resources and clusters to be in the same namespace.
📖 ClusterResourceSet is namespace scoped
k8s-ci-robot and others added 23 commits May 13, 2026 17:51
…bot/cherry-pick-13685-to-release-1.13

[release-1.13] 🌱 KCP cleanup etcd members not started after a machine is remediated
Squash follow-up OWNERS sync into the initial OpenShift-specific carry since it
updates the same initial ownership surface.

# Conflicts:
#	.github/workflows/pr-dependabot.yaml
#	.github/workflows/pr-golangci-lint.yaml
#	.github/workflows/pr-verify.yaml
#	OWNERS_ALIASES
Squash the OWNERS-only carries into a single update to keep ownership churn in
one focused commit.
Squash adjacent changes that iterate on OpenShift manifest tooling and
metadata sync behavior in the same Makefile-driven flow.
Squash adjacent Dockerfile updates that refine the 4.21 image carry and
manager binary naming.
Squash adjacent toolchain updates touching openshift/tools so kustomize
alignment and IPAM pinning are applied together.
…olicy: Ignore

Add functions to set the failurePolicy to Ignore for both mutating and validating webhooks handling IPAM resources.

During bootstrap, the bootstrap node's Kube API Server receives IPAM create requests but is unable
to reach the webhooks in the Cluster API namespace.

This is because the bootstrap node doesn't have a route to the pods as it doesn't have access to the pod networks.
If failurePolicy is set to Fail, the KAS cannot reach the webhook endpoints and the request fails, preventing creation of IPAddress and IPAddressClaim resources.

This causes a chicken-and-egg problem as it prevents IPAM provisioning
for the workers which won't start without their IP addresses being allocated.

Setting failurePolicy to Ignore allows the resources to be created even when the webhooks are
unreachable during bootstrap, matching what Machine API also does.

More context: https://redhat-internal.slack.com/archives/C0A2M43S199/p1765540108488539
Squash ART image consistency updates into a single carry commit.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Squash adjacent carries that iterate over OpenShift manifests generation,
IPAM kustomization, and Dockerfile image consistency.
… upstream rebase

Squash the post-rebase regeneration steps into a single carry commit so the
PR keeps one coherent update for generated manifests and dependency vendoring.
Signed-off-by: Nolan Brubaker <nolan@nbrubaker.com>
@openshift-ci openshift-ci Bot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label May 25, 2026
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented May 25, 2026

Hi @cloud-team-rebase-bot[bot]. Thanks for your PR.

I'm waiting for a openshift member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 25, 2026

Walkthrough

Consolidates API/CRD updates (taints, rollouts, health checks), conversions, kubeadm controllers/webhooks, cluster cache behavior, clusterctl provider/image handling, CI/workflows, and build/test tooling versions; repins webhooks to v1, removes legacy versions/exclusions, adds tests, and updates Docker/Makefile/Tilt.

Changes

CAPI 1.12/1.13 stabilization: APIs, webhooks, tooling, and ops

Layer / File(s) Summary
API/CRD, controllers, webhooks, clusterctl, and CI/tooling refresh
api/*, config/crd/*, bootstrap/*, controllers/*, cmd/clusterctl/*, .github/workflows/*, Makefile, Dockerfile, Tiltfile, config/*, CHANGELOG/*, others
Implements taints/rollout/health-check APIs and conversions, repins webhooks/CRDs to v1, updates kubeadm webhooks/controllers and cluster cache, adds provider/image meta handling in clusterctl, and refreshes CI/tooling and build args; includes tests and changelog entries.

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120+ minutes

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

@openshift-ci openshift-ci Bot requested review from nrb and racheljpg May 25, 2026 07:19
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented May 25, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: cloud-team-rebase-bot[bot]
Once this PR has been reviewed and has the lgtm label, please assign radekmanak for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 8

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@api/bootstrap/kubeadm/v1beta1/kubeadmconfig_types.go`:
- Around line 800-807: KubeadmConfigSpec.Validate in v1beta1 does not enforce
that the sum of percentages in DiskLayout (slice of PartitionSpec) is <= 100;
add validation inside KubeadmConfigSpec.Validate to iterate over
spec.DiskLayout, sum the PartitionSpec percentage field (e.g.,
PartitionSpec.Percentage or the actual field name used) and return a validation
error (matching existing API validation style) when the total > 100; ensure the
check runs only when DiskLayout is present/len>0 and include the same logic for
any other similar fields mentioned (lines 809-826) so invalid configs are
rejected at admission time.

In `@api/controlplane/kubeadm/v1beta1/conversion.go`:
- Around line 420-427: The conversion currently appends taints into
out.Spec.Taints which can retain stale entries when `out` is reused; change the
logic to build the slice from scratch by resetting `out.Spec.Taints` (e.g.,
assign a new slice with len 0 or make with proper length) before iterating over
`in.Taints`, then append each clusterv1.MachineTaint (Key, Value, Effect,
Propagation) — follow the same overwrite pattern used in the `ReadinessGates`
conversion above; apply this exact fix to the three other reverse/template
conversion blocks that handle taints as well (the similar append loops at the
other noted locations).

In `@api/core/v1beta1/common_types.go`:
- Around line 376-382: The MachineTaint.Value field currently has a
+kubebuilder:validation:MinLength=1 which prohibits empty-string taint values;
remove that MinLength tag on the Value string field in
api/core/v1beta1/common_types.go (the Value field on the MachineTaint struct) so
empty "" values are allowed while keeping the existing MaxLength and Pattern
annotations.

In `@CHANGELOG/v1.12.2.md`:
- Line 16: In the changelog entry replace the double-space typo in the text
"client  cert/key" with a single space so it reads "client cert/key" (update the
exact string in CHANGELOG/v1.12.2.md, locating the line containing "Runtime SDK:
Improve client  cert/key rotation of the RuntimeSDK client (`#13217`)" and change
"client  cert/key" → "client cert/key").

In `@CHANGELOG/v1.13.0-beta.0.md`:
- Line 81: There's a double-space typo in the changelog bullet "Runtime SDK:
Improve client  cert/key rotation of the RuntimeSDK client (`#13213`)"; update
that line (the bullet text) to "Runtime SDK: Improve client cert/key rotation of
the RuntimeSDK client (`#13213`)" by removing the extra space between "client" and
"cert/key".

In `@CHANGELOG/v1.13.0-beta.1.md`:
- Line 148: Update the Runtime SDK bullet in the changelog to fix the
double-space typo: replace "client  cert/key" with "client cert/key" in the
Runtime SDK line ("Runtime SDK: Improve client  cert/key rotation of the
RuntimeSDK client (`#13213`)") so the entry reads "Runtime SDK: Improve client
cert/key rotation of the RuntimeSDK client (`#13213`)".

In `@config/crd/bases/cluster.x-k8s.io_machinedeployments.yaml`:
- Around line 551-613: The key property on MachineTaint currently only enforces
overall length (maxLength: 317) which allows a long name segment after
'/'—restore the per-segment validation by adding an x-kubernetes-validations
rule on properties.key (the MachineTaint schema) that enforces the segment after
an optional prefix slash is max 63 characters (and the optional prefix remains
within its 253 limit), i.e. add a validation regex/rule that checks "(optional
prefix/)?nameSegment" and requires nameSegment length <=63; apply the same
x-kubernetes-validations to the corresponding MachinePool/shared taint schema so
both CRDs stay aligned.

In `@controllers/clustercache/cluster_cache.go`:
- Around line 63-67: The cluster filter Option (Options.ClusterFilter) is never
wired into the clusterCache, leaving cc.clusterFilter nil so the filter branch
in Reconcile never runs; update the SetupWithManager code that constructs
clusterCache to pass Options.ClusterFilter into the clusterCache initialization
(set cc.clusterFilter = opts.ClusterFilter or provide it as a constructor
parameter) so clusterCache.clusterFilter is populated and Reconcile can evaluate
the filter.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: dbb01f75-4b28-4c2f-a3f4-07e3767856cb

📥 Commits

Reviewing files that changed from the base of the PR and between 0a73a68 and 9a34464.

⛔ Files ignored due to path filters (29)
  • api/bootstrap/kubeadm/v1beta1/zz_generated.conversion.go is excluded by !**/zz_generated*
  • api/bootstrap/kubeadm/v1beta1/zz_generated.deepcopy.go is excluded by !**/zz_generated*
  • api/bootstrap/kubeadm/v1beta2/zz_generated.deepcopy.go is excluded by !**/zz_generated*
  • api/controlplane/kubeadm/v1beta1/zz_generated.conversion.go is excluded by !**/zz_generated*
  • api/controlplane/kubeadm/v1beta1/zz_generated.deepcopy.go is excluded by !**/zz_generated*
  • api/controlplane/kubeadm/v1beta2/zz_generated.deepcopy.go is excluded by !**/zz_generated*
  • api/core/v1beta1/zz_generated.conversion.go is excluded by !**/zz_generated*
  • api/core/v1beta1/zz_generated.deepcopy.go is excluded by !**/zz_generated*
  • api/core/v1beta1/zz_generated.openapi.go is excluded by !**/zz_generated*
  • api/core/v1beta2/zz_generated.deepcopy.go is excluded by !**/zz_generated*
  • api/core/v1beta2/zz_generated.openapi.go is excluded by !**/zz_generated*
  • api/runtime/hooks/v1alpha1/zz_generated.deepcopy.go is excluded by !**/zz_generated*
  • api/runtime/hooks/v1alpha1/zz_generated.openapi.go is excluded by !**/zz_generated*
  • docs/book/src/images/clusterclass-crd-relationships.svg is excluded by !**/*.svg
  • docs/book/src/images/kubeadm-control-plane-machines-resources.png is excluded by !**/*.png
  • docs/book/src/images/worker-machines-resources.png is excluded by !**/*.png
  • go.sum is excluded by !**/*.sum
  • hack/tools/go.sum is excluded by !**/*.sum
  • hack/tools/vendor/cloud.google.com/go/auth/CHANGES.md is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/credentials/detect.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/credentials/filetypes.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/credentials/internal/gdch/gdch.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/grpctransport/grpctransport.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/httptransport/httptransport.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/httptransport/transport.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/internal/credsfile/credsfile.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/internal/credsfile/filetype.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/internal/credsfile/parse.go is excluded by !**/vendor/**
  • hack/tools/vendor/cloud.google.com/go/auth/internal/internal.go is excluded by !**/vendor/**
📒 Files selected for processing (271)
  • .dockerignore
  • .github/workflows/pr-gh-workflow-approve.yaml
  • .github/workflows/pr-md-link-check.yaml
  • .github/workflows/release.yaml
  • .github/workflows/weekly-md-link-check.yaml
  • .github/workflows/weekly-security-scan.yaml
  • .github/workflows/weekly-test-release.yaml
  • .golangci-kal.yml
  • .golangci.yml
  • .trivyignore
  • CHANGELOG/v1.10.10.md
  • CHANGELOG/v1.10.9.md
  • CHANGELOG/v1.11.4.md
  • CHANGELOG/v1.11.5.md
  • CHANGELOG/v1.11.6.md
  • CHANGELOG/v1.11.7.md
  • CHANGELOG/v1.12.0-rc.1.md
  • CHANGELOG/v1.12.0.md
  • CHANGELOG/v1.12.1.md
  • CHANGELOG/v1.12.2.md
  • CHANGELOG/v1.12.3.md
  • CHANGELOG/v1.12.4.md
  • CHANGELOG/v1.13.0-beta.0.md
  • CHANGELOG/v1.13.0-beta.1.md
  • CHANGELOG/v1.13.0-rc.0.md
  • CONTRIBUTING.md
  • Dockerfile
  • Makefile
  • Tiltfile
  • api/bootstrap/kubeadm/v1beta1/conversion.go
  • api/bootstrap/kubeadm/v1beta1/kubeadm_types.go
  • api/bootstrap/kubeadm/v1beta1/kubeadmconfig_types.go
  • api/bootstrap/kubeadm/v1beta2/kubeadmconfig_types.go
  • api/controlplane/kubeadm/v1beta1/conversion.go
  • api/controlplane/kubeadm/v1beta1/kubeadm_control_plane_types.go
  • api/controlplane/kubeadm/v1beta1/kubeadmcontrolplanetemplate_types.go
  • api/controlplane/kubeadm/v1beta2/kubeadm_control_plane_types.go
  • api/controlplane/kubeadm/v1beta2/kubeadmcontrolplanetemplate_types.go
  • api/core/v1beta1/cluster_types.go
  • api/core/v1beta1/clusterclass_types.go
  • api/core/v1beta1/common_types.go
  • api/core/v1beta1/conversion.go
  • api/core/v1beta1/conversion_test.go
  • api/core/v1beta1/machine_types.go
  • api/core/v1beta1/machinehealthcheck_types.go
  • api/core/v1beta2/cluster_types.go
  • api/core/v1beta2/clusterclass_types.go
  • api/core/v1beta2/common_types.go
  • api/core/v1beta2/condition_types.go
  • api/core/v1beta2/machine_types.go
  • api/ipam/v1alpha1/conversion.go
  • api/runtime/hooks/v1alpha1/common_types.go
  • api/runtime/hooks/v1alpha1/lifecyclehooks_types.go
  • api/runtime/hooks/v1alpha1/topologymutation_types.go
  • api/runtime/hooks/v1alpha1/topologymutation_variable_types.go
  • bootstrap/kubeadm/config/crd/bases/bootstrap.cluster.x-k8s.io_kubeadmconfigs.yaml
  • bootstrap/kubeadm/config/crd/bases/bootstrap.cluster.x-k8s.io_kubeadmconfigtemplates.yaml
  • bootstrap/kubeadm/config/crd/patches/webhook_in_kubeadmconfigs.yaml
  • bootstrap/kubeadm/config/crd/patches/webhook_in_kubeadmconfigtemplates.yaml
  • bootstrap/kubeadm/config/manager/manager.yaml
  • bootstrap/kubeadm/config/webhook/manifests.yaml
  • bootstrap/kubeadm/internal/cloudinit/cloudinit_test.go
  • bootstrap/kubeadm/internal/cloudinit/disk_setup.go
  • bootstrap/kubeadm/internal/cloudinit/utils.go
  • bootstrap/kubeadm/internal/controllers/kubeadmconfig_controller.go
  • bootstrap/kubeadm/internal/controllers/suite_test.go
  • bootstrap/kubeadm/internal/locking/control_plane_init_mutex.go
  • bootstrap/kubeadm/internal/setup/setup.go
  • bootstrap/kubeadm/internal/webhooks/kubeadmconfig.go
  • bootstrap/kubeadm/internal/webhooks/kubeadmconfig_test.go
  • bootstrap/kubeadm/internal/webhooks/kubeadmconfigtemplate.go
  • bootstrap/kubeadm/internal/webhooks/kubeadmconfigtemplate_test.go
  • bootstrap/kubeadm/main.go
  • bootstrap/util/configowner_test.go
  • bootstrap/util/suite_test.go
  • cmd/clusterctl/Dockerfile
  • cmd/clusterctl/client/cluster/cert_manager.go
  • cmd/clusterctl/client/cluster/cert_manager_test.go
  • cmd/clusterctl/client/cluster/mover.go
  • cmd/clusterctl/client/cluster/template.go
  • cmd/clusterctl/client/cluster/template_test.go
  • cmd/clusterctl/client/cluster/upgrader.go
  • cmd/clusterctl/client/cluster/upgrader_test.go
  • cmd/clusterctl/client/config/imagemeta_client.go
  • cmd/clusterctl/client/config/imagemeta_client_test.go
  • cmd/clusterctl/client/config/providers_client.go
  • cmd/clusterctl/client/config_test.go
  • cmd/clusterctl/client/repository/repository_github.go
  • cmd/clusterctl/client/repository/repository_github_test.go
  • cmd/clusterctl/client/upgrade.go
  • cmd/clusterctl/cmd/config_repositories_test.go
  • cmd/clusterctl/cmd/describe_cluster.go
  • cmd/clusterctl/cmd/upgrade_apply.go
  • cmd/clusterctl/cmd/version_checker.go
  • cmd/clusterctl/config/crd/bases/clusterctl.cluster.x-k8s.io_metadata.yaml
  • cmd/clusterctl/config/crd/bases/clusterctl.cluster.x-k8s.io_providers.yaml
  • cmd/clusterctl/config/manifest/clusterctl-api.yaml
  • cmd/clusterctl/hack/create-local-repository.py
  • cmd/clusterctl/internal/test/fake_github.go
  • cmd/clusterctl/internal/test/fake_reader.go
  • config/crd/bases/addons.cluster.x-k8s.io_clusterresourcesetbindings.yaml
  • config/crd/bases/addons.cluster.x-k8s.io_clusterresourcesets.yaml
  • config/crd/bases/cluster.x-k8s.io_clusterclasses.yaml
  • config/crd/bases/cluster.x-k8s.io_clusters.yaml
  • config/crd/bases/cluster.x-k8s.io_machinedeployments.yaml
  • config/crd/bases/cluster.x-k8s.io_machinedrainrules.yaml
  • config/crd/bases/cluster.x-k8s.io_machinehealthchecks.yaml
  • config/crd/bases/cluster.x-k8s.io_machinepools.yaml
  • config/crd/bases/cluster.x-k8s.io_machines.yaml
  • config/crd/bases/cluster.x-k8s.io_machinesets.yaml
  • config/crd/bases/ipam.cluster.x-k8s.io_ipaddressclaims.yaml
  • config/crd/bases/ipam.cluster.x-k8s.io_ipaddresses.yaml
  • config/crd/bases/runtime.cluster.x-k8s.io_extensionconfigs.yaml
  • config/crd/patches/webhook_in_clusterclasses.yaml
  • config/crd/patches/webhook_in_clusterresourcesetbindings.yaml
  • config/crd/patches/webhook_in_clusterresourcesets.yaml
  • config/crd/patches/webhook_in_clusters.yaml
  • config/crd/patches/webhook_in_extensionconfigs.yaml
  • config/crd/patches/webhook_in_ipaddressclaims.yaml
  • config/crd/patches/webhook_in_ipaddresses.yaml
  • config/crd/patches/webhook_in_machinedeployments.yaml
  • config/crd/patches/webhook_in_machinedrainrules.yaml
  • config/crd/patches/webhook_in_machinehealthchecks.yaml
  • config/crd/patches/webhook_in_machinepools.yaml
  • config/crd/patches/webhook_in_machines.yaml
  • config/crd/patches/webhook_in_machinesets.yaml
  • config/manager/manager.yaml
  • config/metrics/crd-metrics-config.yaml
  • config/webhook/manifests.yaml
  • controllers/clustercache/cluster_accessor.go
  • controllers/clustercache/cluster_accessor_client.go
  • controllers/clustercache/cluster_accessor_test.go
  • controllers/clustercache/cluster_cache.go
  • controllers/clustercache/cluster_cache_test.go
  • controllers/crdmigrator/crd_migrator.go
  • controllers/crdmigrator/test/t1/crd/test.cluster.x-k8s.io_testclusters.yaml
  • controllers/crdmigrator/test/t2/crd/test.cluster.x-k8s.io_testclusters.yaml
  • controllers/crdmigrator/test/t3/crd/test.cluster.x-k8s.io_testclusters.yaml
  • controllers/crdmigrator/test/t4/crd/test.cluster.x-k8s.io_testclusters.yaml
  • controlplane/kubeadm/config/crd/bases/controlplane.cluster.x-k8s.io_kubeadmcontrolplanes.yaml
  • controlplane/kubeadm/config/crd/bases/controlplane.cluster.x-k8s.io_kubeadmcontrolplanetemplates.yaml
  • controlplane/kubeadm/config/crd/patches/webhook_in_kubeadmcontrolplanes.yaml
  • controlplane/kubeadm/config/crd/patches/webhook_in_kubeadmcontrolplanetemplates.yaml
  • controlplane/kubeadm/config/manager/manager.yaml
  • controlplane/kubeadm/config/webhook/manifests.yaml
  • controlplane/kubeadm/internal/cluster.go
  • controlplane/kubeadm/internal/cluster_test.go
  • controlplane/kubeadm/internal/clustercache_utils.go
  • controlplane/kubeadm/internal/control_plane.go
  • controlplane/kubeadm/internal/control_plane_test.go
  • controlplane/kubeadm/internal/controllers/controller.go
  • controlplane/kubeadm/internal/controllers/controller_test.go
  • controlplane/kubeadm/internal/controllers/fakes_test.go
  • controlplane/kubeadm/internal/controllers/helpers.go
  • controlplane/kubeadm/internal/controllers/inplace.go
  • controlplane/kubeadm/internal/controllers/inplace_canupdatemachine.go
  • controlplane/kubeadm/internal/controllers/inplace_canupdatemachine_test.go
  • controlplane/kubeadm/internal/controllers/inplace_trigger.go
  • controlplane/kubeadm/internal/controllers/remediation.go
  • controlplane/kubeadm/internal/controllers/remediation_test.go
  • controlplane/kubeadm/internal/controllers/scale.go
  • controlplane/kubeadm/internal/controllers/scale_test.go
  • controlplane/kubeadm/internal/controllers/status.go
  • controlplane/kubeadm/internal/controllers/status_test.go
  • controlplane/kubeadm/internal/controllers/suite_test.go
  • controlplane/kubeadm/internal/controllers/update.go
  • controlplane/kubeadm/internal/controllers/update_test.go
  • controlplane/kubeadm/internal/desiredstate/desired_state.go
  • controlplane/kubeadm/internal/desiredstate/desired_state_test.go
  • controlplane/kubeadm/internal/etcd/etcd_test.go
  • controlplane/kubeadm/internal/etcd/fake/client.go
  • controlplane/kubeadm/internal/setup/setup.go
  • controlplane/kubeadm/internal/suite_test.go
  • controlplane/kubeadm/internal/webhooks/kubeadmcontrolplane.go
  • controlplane/kubeadm/internal/webhooks/kubeadmcontrolplane_test.go
  • controlplane/kubeadm/internal/webhooks/kubeadmcontrolplanetemplate.go
  • controlplane/kubeadm/internal/webhooks/scale.go
  • controlplane/kubeadm/internal/workload_cluster.go
  • controlplane/kubeadm/internal/workload_cluster_conditions.go
  • controlplane/kubeadm/internal/workload_cluster_conditions_test.go
  • controlplane/kubeadm/internal/workload_cluster_coredns.go
  • controlplane/kubeadm/internal/workload_cluster_etcd.go
  • controlplane/kubeadm/internal/workload_cluster_etcd_test.go
  • controlplane/kubeadm/internal/workload_cluster_rbac.go
  • controlplane/kubeadm/internal/workload_cluster_rbac_test.go
  • controlplane/kubeadm/internal/workload_cluster_test.go
  • controlplane/kubeadm/main.go
  • docs/book/src/SUMMARY.md
  • docs/book/src/clusterctl/configuration.md
  • docs/book/src/developer/core/logging.md
  • docs/book/src/developer/core/tilt.md
  • docs/book/src/developer/providers/contracts/bootstrap-config.md
  • docs/book/src/developer/providers/contracts/clusterctl.md
  • docs/book/src/developer/providers/contracts/control-plane.md
  • docs/book/src/developer/providers/contracts/infra-cluster.md
  • docs/book/src/developer/providers/contracts/infra-machine.md
  • docs/book/src/developer/providers/contracts/infra-machinepool.md
  • docs/book/src/developer/providers/getting-started/webhooks.md
  • docs/book/src/developer/providers/migrations/v1.10-to-v1.11.md
  • docs/book/src/developer/providers/migrations/v1.12-to-v1.13.md
  • docs/book/src/developer/providers/migrations/v1.9-to-v1.10.md
  • docs/book/src/images/kubeadm-control-plane-machines-resources.plantuml
  • docs/book/src/images/worker-machines-resources.plantuml
  • docs/book/src/introduction.md
  • docs/book/src/reference/api/crd-api-reference-v1beta1.md
  • docs/book/src/reference/api/crd-api-reference.md
  • docs/book/src/reference/api/crd-relationships.md
  • docs/book/src/reference/api/reference.md
  • docs/book/src/reference/versions.md
  • docs/book/src/tasks/automated-machine-management/healthchecking.md
  • docs/book/src/tasks/automated-machine-management/scaling.md
  • docs/book/src/tasks/cluster-resource-set.md
  • docs/book/src/tasks/diagnostics.md
  • docs/book/src/tasks/experimental-features/cluster-class/write-clusterclass.md
  • docs/book/src/tasks/experimental-features/experimental-features.md
  • docs/book/src/tasks/experimental-features/machine-pools.md
  • docs/book/src/tasks/experimental-features/runtime-sdk/implement-extensions.md
  • docs/book/src/tasks/experimental-features/runtime-sdk/index.md
  • docs/book/src/tasks/external-etcd.md
  • docs/book/src/tasks/using-kustomize.md
  • docs/book/src/user/quick-start.md
  • docs/proposals/20200506-conditions.md
  • docs/proposals/20210310-opt-in-autoscaling-from-zero.md
  • docs/proposals/20220330-topology-mutation-hook.md
  • docs/proposals/20240916-improve-status-in-CAPI-resources.md
  • docs/proposals/20250124-From CAPD(docker) to CAPD(dev) .md
  • docs/release/releases/release-1.13.md
  • docs/release/role-handbooks/ci-signal/README.md
  • docs/release/role-handbooks/release-lead/README.md
  • exp/topology/desiredstate/desired_state.go
  • exp/topology/desiredstate/desired_state_test.go
  • exp/topology/desiredstate/lifecycle_hooks.go
  • exp/topology/desiredstate/lifecycle_hooks_test.go
  • exp/topology/desiredstate/upgrade_plan.go
  • exp/topology/desiredstate/upgrade_plan_test.go
  • feature/feature.go
  • go.mod
  • hack/crd-ref-docs-config-v1beta1.yaml
  • hack/crd-ref-docs-config-v1beta2.yaml
  • hack/ensure-go.sh
  • hack/gogcflags.sh
  • hack/kind-install.sh
  • hack/observability/alloy/kustomization.yaml
  • hack/observability/grafana/chart/kustomization.yaml
  • hack/observability/grafana/dashboards/cluster-api-mgmt-apiserver-requests.json
  • hack/observability/grafana/dashboards/cluster-api-performance.json
  • hack/observability/grafana/dashboards/cluster-api-state.json
  • hack/observability/grafana/dashboards/cluster-api-wl-apiserver-requests.json
  • hack/observability/grafana/dashboards/controller-runtime.json
  • hack/observability/grafana/dashboards/runtime-extensions.json
  • hack/observability/kube-state-metrics/crd-sidecar-patch.yaml
  • hack/observability/kube-state-metrics/kustomization.yaml
  • hack/observability/loki/kustomization.yaml
  • hack/observability/loki/values.yaml
  • hack/observability/metrics-server/kustomization.yaml
  • hack/observability/parca/values.yaml
  • hack/observability/prometheus/kustomization.yaml
  • hack/observability/prometheus/values.yaml
  • hack/observability/tempo/kustomization.yaml
  • hack/observability/visualizer/kustomization.yaml
  • hack/tools/go.mod
  • hack/tools/govulncheck/.gitignore
  • hack/tools/govulncheck/govulncheck.patch
  • hack/tools/internal/tilt-prepare/main.go
  • hack/tools/prowjob-gen/config.go
  • hack/tools/prowjob-gen/test/test-configuration.yaml
  • hack/tools/prowjob-gen/test/test-main.yaml.golden
  • hack/tools/prowjob-gen/test/test.yaml.tpl
  • hack/tools/release/internal/update_providers/provider_issues.go
  • hack/tools/release/weekly/main.go
  • hack/tools/runtime-openapi-gen/main.go
💤 Files with no reviewable changes (7)
  • .github/workflows/pr-gh-workflow-approve.yaml
  • .trivyignore
  • bootstrap/kubeadm/config/webhook/manifests.yaml
  • controllers/clustercache/cluster_accessor_test.go
  • cmd/clusterctl/client/cluster/upgrader_test.go
  • config/webhook/manifests.yaml
  • bootstrap/util/suite_test.go

Comment on lines +800 to +807
// diskLayout specifies an ordered list of partitions, where each item defines the
// percentage of disk space and optional partition type for that partition.
// The sum of all partition percentages must not be greater than 100.
// +optional
// +kubebuilder:validation:MinItems=1
// +kubebuilder:validation:MaxItems=100
DiskLayout []PartitionSpec `json:"diskLayout,omitempty"`
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Enforce diskLayout total percentage limit in v1beta1 validation.

Partition.DiskLayout documents that total percentage must be <= 100, but KubeadmConfigSpec.Validate does not currently check this in v1beta1. Invalid specs can pass admission and fail later at bootstrap time.

🔧 Proposed fix
func (c *KubeadmConfigSpec) Validate(pathPrefix *field.Path) field.ErrorList {
    var allErrs field.ErrorList

    allErrs = append(allErrs, c.validateFiles(pathPrefix)...)
    allErrs = append(allErrs, c.validateUsers(pathPrefix)...)
    allErrs = append(allErrs, c.validateIgnition(pathPrefix)...)
+   allErrs = append(allErrs, c.validateDiskSetup(pathPrefix)...)

    // Validate JoinConfiguration.
    if c.JoinConfiguration != nil {
        ...
    }

    return allErrs
}
+
+func (c *KubeadmConfigSpec) validateDiskSetup(pathPrefix *field.Path) field.ErrorList {
+   var allErrs field.ErrorList
+   if c.DiskSetup == nil {
+       return allErrs
+   }
+   for i, partition := range c.DiskSetup.Partitions {
+       var total int32
+       for _, p := range partition.DiskLayout {
+           total += p.Percentage
+       }
+       if total > 100 {
+           allErrs = append(allErrs, field.Invalid(
+               pathPrefix.Child("diskSetup", "partitions").Index(i).Child("diskLayout"),
+               total,
+               "the sum of all partition percentages must not be greater than 100",
+           ))
+       }
+   }
+   return allErrs
+}

Also applies to: 809-826

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@api/bootstrap/kubeadm/v1beta1/kubeadmconfig_types.go` around lines 800 - 807,
KubeadmConfigSpec.Validate in v1beta1 does not enforce that the sum of
percentages in DiskLayout (slice of PartitionSpec) is <= 100; add validation
inside KubeadmConfigSpec.Validate to iterate over spec.DiskLayout, sum the
PartitionSpec percentage field (e.g., PartitionSpec.Percentage or the actual
field name used) and return a validation error (matching existing API validation
style) when the total > 100; ensure the check runs only when DiskLayout is
present/len>0 and include the same logic for any other similar fields mentioned
(lines 809-826) so invalid configs are rejected at admission time.

Comment on lines +420 to +427
for _, c := range in.Taints {
out.Spec.Taints = append(out.Spec.Taints, clusterv1.MachineTaint{
Key: c.Key,
Value: c.Value,
Effect: c.Effect,
Propagation: clusterv1.MachineTaintPropagation(c.Propagation),
})
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Overwrite taints instead of appending during conversion.

These helpers append into the destination slice without resetting it first. If out is reused, stale taints get retained and the converted object can accumulate duplicates. Build the slice from scratch, like the ReadinessGates conversion right above.

Proposed fix
-	for _, c := range in.Taints {
-		out.Spec.Taints = append(out.Spec.Taints, clusterv1.MachineTaint{
-			Key:         c.Key,
-			Value:       c.Value,
-			Effect:      c.Effect,
-			Propagation: clusterv1.MachineTaintPropagation(c.Propagation),
-		})
-	}
+	if len(in.Taints) > 0 {
+		out.Spec.Taints = make([]clusterv1.MachineTaint, len(in.Taints))
+		for i := range in.Taints {
+			c := in.Taints[i]
+			out.Spec.Taints[i] = clusterv1.MachineTaint{
+				Key:         c.Key,
+				Value:       c.Value,
+				Effect:      c.Effect,
+				Propagation: clusterv1.MachineTaintPropagation(c.Propagation),
+			}
+		}
+	} else {
+		out.Spec.Taints = nil
+	}

Apply the same overwrite pattern to the three reverse/template conversion blocks as well.

Also applies to: 446-453, 464-471, 482-489

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@api/controlplane/kubeadm/v1beta1/conversion.go` around lines 420 - 427, The
conversion currently appends taints into out.Spec.Taints which can retain stale
entries when `out` is reused; change the logic to build the slice from scratch
by resetting `out.Spec.Taints` (e.g., assign a new slice with len 0 or make with
proper length) before iterating over `in.Taints`, then append each
clusterv1.MachineTaint (Key, Value, Effect, Propagation) — follow the same
overwrite pattern used in the `ReadinessGates` conversion above; apply this
exact fix to the three other reverse/template conversion blocks that handle
taints as well (the similar append loops at the other noted locations).

Comment on lines +376 to +382
// value is the taint value corresponding to the taint key.
// It must be a valid label value of maximum size 63 characters.
// +optional
// +kubebuilder:validation:MinLength=1
// +kubebuilder:validation:MaxLength=63
// +kubebuilder:validation:Pattern=^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$
Value string `json:"value,omitempty"`
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🌐 Web query:

Kubernetes core/v1 Taint API validation: is an empty string allowed for Taint.value, and does a valid label value permit the empty string?

💡 Result:

In Kubernetes core/v1, Taint.value: 1) Is an empty string allowed for Taint.value? Yes. The API validation only checks Taint.value with label-value validation when taint.Value is non-empty. If taint.Value == "" then the value validation is skipped, so an empty string is accepted by this validation path. [1] 2) Does a valid label value permit the empty string? No. A “valid label value” is a specific non-empty string pattern validated by Kubernetes’ label validation; there is no rule here that says a valid label value includes (or permits) the empty string. The empty string is accepted only because Kubernetes skips label-value validation when the taint value is empty. [1] Notes/implications: - When Taint.value is empty, Kubernetes will not enforce the label-value format for it (it passes validation). [1] - When Taint.value is non-empty, Kubernetes enforces label-value validity via validation.IsValidLabelValue(taint.Value); invalid non-empty values are rejected. [1]

Citations:


Allow MachineTaint.value: "" to match Kubernetes taint semantics.

MachineTaint is documented as corev1.Taint-compatible, but +kubebuilder:validation:MinLength=1 rejects an explicit empty string. Kubernetes accepts empty taint values by skipping label-value validation when taint.Value == "", so this change makes the CRD stricter without gain.

Proposed fix
 	// value is the taint value corresponding to the taint key.
 	// It must be a valid label value of maximum size 63 characters.
 	// +optional
-	// +kubebuilder:validation:MinLength=1
 	// +kubebuilder:validation:MaxLength=63
 	// +kubebuilder:validation:Pattern=^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$
 	Value string `json:"value,omitempty"`
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
// value is the taint value corresponding to the taint key.
// It must be a valid label value of maximum size 63 characters.
// +optional
// +kubebuilder:validation:MinLength=1
// +kubebuilder:validation:MaxLength=63
// +kubebuilder:validation:Pattern=^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$
Value string `json:"value,omitempty"`
// value is the taint value corresponding to the taint key.
// It must be a valid label value of maximum size 63 characters.
// +optional
// +kubebuilder:validation:MaxLength=63
// +kubebuilder:validation:Pattern=^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$
Value string `json:"value,omitempty"`
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@api/core/v1beta1/common_types.go` around lines 376 - 382, The
MachineTaint.Value field currently has a +kubebuilder:validation:MinLength=1
which prohibits empty-string taint values; remove that MinLength tag on the
Value string field in api/core/v1beta1/common_types.go (the Value field on the
MachineTaint struct) so empty "" values are allowed while keeping the existing
MaxLength and Pattern annotations.

Comment thread CHANGELOG/v1.12.2.md
## :bug: Bug Fixes
- API: Fix v1beta1 ControlPlane contract to handle .status.initialized correctly (#13188)
- ClusterClass: Allow adding spec via ClusterClass JSON patches (#13226)
- Runtime SDK: Improve client cert/key rotation of the RuntimeSDK client (#13217)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Fix double-space typo in bug-fix entry.

There is an extra space in client cert/key; please change it to client cert/key.

🧰 Tools
🪛 LanguageTool

[grammar] ~16-~16: Ensure spelling is correct
Context: ...mprove client cert/key rotation of the RuntimeSDK client (#13217) - Testing: Fix webhook ...

(QB_NEW_EN_ORTHOGRAPHY_ERROR_IDS_1)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@CHANGELOG/v1.12.2.md` at line 16, In the changelog entry replace the
double-space typo in the text "client  cert/key" with a single space so it reads
"client cert/key" (update the exact string in CHANGELOG/v1.12.2.md, locating the
line containing "Runtime SDK: Improve client  cert/key rotation of the
RuntimeSDK client (`#13217`)" and change "client  cert/key" → "client cert/key").

- Machine/MachineSet/MachineDeployment: Fix UpToDate calculation for rolloutAfter (#13404)
- MachineSet: Use MachineSet template values in completeMoveMachine for in-place updates (#13059)
- Misc: Fix bug while setting status for deprecated fields (#13336)
- Runtime SDK: Improve client cert/key rotation of the RuntimeSDK client (#13213)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Fix double-space typo in Runtime SDK bullet.

client cert/key has an extra space; use client cert/key.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@CHANGELOG/v1.13.0-beta.0.md` at line 81, There's a double-space typo in the
changelog bullet "Runtime SDK: Improve client  cert/key rotation of the
RuntimeSDK client (`#13213`)"; update that line (the bullet text) to "Runtime SDK:
Improve client cert/key rotation of the RuntimeSDK client (`#13213`)" by removing
the extra space between "client" and "cert/key".

- Machine/MachineSet/MachineDeployment: Fix UpToDate calculation for rolloutAfter (#13404)
- MachineSet: Use MachineSet template values in completeMoveMachine for in-place updates (#13059)
- Misc: Fix bug while setting status for deprecated fields (#13336)
- Runtime SDK: Improve client cert/key rotation of the RuntimeSDK client (#13213)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Fix double-space typo in Runtime SDK bullet.

client cert/key should be client cert/key.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@CHANGELOG/v1.13.0-beta.1.md` at line 148, Update the Runtime SDK bullet in
the changelog to fix the double-space typo: replace "client  cert/key" with
"client cert/key" in the Runtime SDK line ("Runtime SDK: Improve client 
cert/key rotation of the RuntimeSDK client (`#13213`)") so the entry reads
"Runtime SDK: Improve client cert/key rotation of the RuntimeSDK client
(`#13213`)".

Comment on lines +551 to +613
taints:
description: |-
taints are the node taints that Cluster API will manage.
This list is not necessarily complete: other Kubernetes components may add or remove other taints from nodes,
e.g. the node controller might add the node.kubernetes.io/not-ready taint.
Only those taints defined in this list will be added or removed by core Cluster API controllers.

There can be at most 64 taints.
A pod would have to tolerate all existing taints to run on the corresponding node.

NOTE: This list is implemented as a "map" type, meaning that individual elements can be managed by different owners.
items:
description: MachineTaint defines a taint equivalent to
corev1.Taint, but additionally having a propagation field.
properties:
effect:
description: effect is the effect for the taint. Valid
values are NoSchedule, PreferNoSchedule and NoExecute.
enum:
- NoSchedule
- PreferNoSchedule
- NoExecute
type: string
key:
description: |-
key is the taint key to be applied to a node.
Must be a valid qualified name of maximum size 63 characters
with an optional subdomain prefix of maximum size 253 characters,
separated by a `/`.
maxLength: 317
minLength: 1
pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*\/)?([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$
type: string
propagation:
description: |-
propagation defines how this taint should be propagated to nodes.
Valid values are 'Always' and 'OnInitialization'.
Always: The taint will be continuously reconciled. If it is not set for a node, it will be added during reconciliation.
OnInitialization: The taint will be added during node initialization. If it gets removed from the node later on it will not get added again.
enum:
- Always
- OnInitialization
type: string
value:
description: |-
value is the taint value corresponding to the taint key.
It must be a valid label value of maximum size 63 characters.
maxLength: 63
minLength: 1
pattern: ^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$
type: string
required:
- effect
- key
- propagation
type: object
maxItems: 64
minItems: 1
type: array
x-kubernetes-list-map-keys:
- key
- effect
x-kubernetes-list-type: map
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Restore per-segment taint key validation.

maxLength: 317 plus the regex only cap the overall string length, so keys like prefix/<70-char-name> now pass CRD admission even though the segment after / must stay within 63 characters. That weakens the CRD contract and defers the failure until taints are reconciled onto Nodes. Please restore the split-length x-kubernetes-validations check in the shared taint schema so this CRD and the MachinePool copy stay aligned.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@config/crd/bases/cluster.x-k8s.io_machinedeployments.yaml` around lines 551 -
613, The key property on MachineTaint currently only enforces overall length
(maxLength: 317) which allows a long name segment after '/'—restore the
per-segment validation by adding an x-kubernetes-validations rule on
properties.key (the MachineTaint schema) that enforces the segment after an
optional prefix slash is max 63 characters (and the optional prefix remains
within its 253 limit), i.e. add a validation regex/rule that checks "(optional
prefix/)?nameSegment" and requires nameSegment length <=63; apply the same
x-kubernetes-validations to the corresponding MachinePool/shared taint schema so
both CRDs stay aligned.

Comment on lines +63 to +67
// ClusterFilter is a function that can be used to filter which clusters should be handled
// by the ClusterCache. If nil, all clusters will be handled. If set, only clusters for which
// the filter returns true will be handled.
ClusterFilter ClusterFilter

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Wire Options.ClusterFilter into clusterCache initialization.

Options.ClusterFilter is introduced on Line 63, but SetupWithManager does not assign it when constructing clusterCache, so cc.clusterFilter remains nil and the filter branch in Reconcile never activates.

🔧 Proposed fix
 cc := &clusterCache{
 	client:                mgr.GetClient(),
 	clusterAccessorConfig: buildClusterAccessorConfig(mgr.GetScheme(), options, controllerPodMetadata),
 	clusterAccessors:      make(map[client.ObjectKey]*clusterAccessor),
 	cacheCtx:              cacheCtx,
 	cacheCtxCancel:        cacheCtxCancel,
+	clusterFilter:         options.ClusterFilter,
 }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
// ClusterFilter is a function that can be used to filter which clusters should be handled
// by the ClusterCache. If nil, all clusters will be handled. If set, only clusters for which
// the filter returns true will be handled.
ClusterFilter ClusterFilter
cc := &clusterCache{
client: mgr.GetClient(),
clusterAccessorConfig: buildClusterAccessorConfig(mgr.GetScheme(), options, controllerPodMetadata),
clusterAccessors: make(map[client.ObjectKey]*clusterAccessor),
cacheCtx: cacheCtx,
cacheCtxCancel: cacheCtxCancel,
clusterFilter: options.ClusterFilter,
}
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@controllers/clustercache/cluster_cache.go` around lines 63 - 67, The cluster
filter Option (Options.ClusterFilter) is never wired into the clusterCache,
leaving cc.clusterFilter nil so the filter branch in Reconcile never runs;
update the SetupWithManager code that constructs clusterCache to pass
Options.ClusterFilter into the clusterCache initialization (set cc.clusterFilter
= opts.ClusterFilter or provide it as a constructor parameter) so
clusterCache.clusterFilter is populated and Reconcile can evaluate the filter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test.

Projects

None yet

Development

Successfully merging this pull request may close these issues.