mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-11 22:20:18 +00:00
Check CIDR before updating node status
This commit is contained in:
@@ -381,7 +381,9 @@ func (kl *Kubelet) tryUpdateNodeStatus(tryNumber int) error {
|
|||||||
return fmt.Errorf("nil %q node object", kl.nodeName)
|
return fmt.Errorf("nil %q node object", kl.nodeName)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if node.Spec.PodCIDR != "" {
|
||||||
kl.updatePodCIDR(node.Spec.PodCIDR)
|
kl.updatePodCIDR(node.Spec.PodCIDR)
|
||||||
|
}
|
||||||
|
|
||||||
kl.setNodeStatus(node)
|
kl.setNodeStatus(node)
|
||||||
// Patch the current status on the API server
|
// Patch the current status on the API server
|
||||||
|
Reference in New Issue
Block a user