mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 03:11:40 +00:00
Merge pull request #103471 from pacoxu/patch-1
kubeadm: fix nil pointer in Cfg() feature gate checking
This commit is contained in:
commit
120f6325a7
@ -93,7 +93,7 @@ func runCleanupNode(c workflow.RunData) error {
|
||||
}
|
||||
resetConfigDir(kubeadmconstants.KubernetesDir, certsDir)
|
||||
|
||||
if features.Enabled(r.Cfg().FeatureGates, features.RootlessControlPlane) {
|
||||
if r.Cfg() != nil && features.Enabled(r.Cfg().FeatureGates, features.RootlessControlPlane) {
|
||||
klog.V(1).Infoln("[reset] Removing users and groups created for rootless control-plane")
|
||||
if err := users.RemoveUsersAndGroups(); err != nil {
|
||||
klog.Warningf("[reset] Failed to remove users and groups: %v\n", err)
|
||||
|
Loading…
Reference in New Issue
Block a user