Merge pull request #133754 from HirazawaUi/automated-cherry-pick-of-#133513-upstream-release-1.33

Automated cherry pick of #133513: Add missing conversion for timeoutForControlPlane
This commit is contained in:
Kubernetes Prow Robot
2025-09-02 23:33:15 -07:00
committed by GitHub

View File

@@ -381,6 +381,11 @@ func documentMapToInitConfiguration(gvkmap kubeadmapi.DocumentMap, allowDeprecat
// If ClusterConfiguration was given, populate it in the InitConfiguration struct
if clustercfg != nil {
initcfg.ClusterConfiguration = *clustercfg
// TODO: Workaround for missing v1beta3 ClusterConfiguration timeout conversion. Remove this conversion once the v1beta3 is removed
if clustercfg.APIServer.TimeoutForControlPlane.Duration != 0 && clustercfg.APIServer.TimeoutForControlPlane.Duration != kubeadmconstants.ControlPlaneComponentHealthCheckTimeout {
initcfg.Timeouts.ControlPlaneComponentHealthCheck.Duration = clustercfg.APIServer.TimeoutForControlPlane.Duration
}
} else {
// Populate the internal InitConfiguration.ClusterConfiguration with defaults
extclustercfg := &kubeadmapiv1.ClusterConfiguration{}