mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-29 22:46:12 +00:00
Merge pull request #2149 from claire921/r_health
Refactor Status.String() in health pkg
This commit is contained in:
commit
0ed0858d1d
@ -103,10 +103,12 @@ func findPortByName(container api.Container, portName string) int {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (s Status) String() string {
|
func (s Status) String() string {
|
||||||
if s == Healthy {
|
switch s {
|
||||||
|
case Healthy:
|
||||||
return "healthy"
|
return "healthy"
|
||||||
} else if s == Unhealthy {
|
case Unhealthy:
|
||||||
return "unhealthy"
|
return "unhealthy"
|
||||||
}
|
default:
|
||||||
return "unknown"
|
return "unknown"
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user