mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-29 14:37:00 +00:00
Messages should be appended to "messages" slice.
Network configuration error message while setting Kubelet status was being written to "reasons" slice. Write this message to "messages" slice instead. Also remove "reasons" slice entirely since it is not used anywhere.
This commit is contained in:
parent
b9293a093b
commit
7a709b09c3
@ -2362,13 +2362,12 @@ func (kl *Kubelet) setNodeStatus(node *api.Node) error {
|
||||
LastHeartbeatTime: currentTime,
|
||||
}
|
||||
} else {
|
||||
var reasons []string
|
||||
var messages []string
|
||||
if !containerRuntimeUp {
|
||||
messages = append(messages, "container runtime is down")
|
||||
}
|
||||
if !networkConfigured {
|
||||
messages = append(reasons, "network not configured correctly")
|
||||
messages = append(messages, "network not configured correctly")
|
||||
}
|
||||
newNodeReadyCondition = api.NodeCondition{
|
||||
Type: api.NodeReady,
|
||||
|
Loading…
Reference in New Issue
Block a user