File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -172,9 +172,7 @@ func GetPodStatus(pod *kcore.Pod) PodStatus {
172
172
numFailed := 0
173
173
numKilled := 0
174
174
for _ , containerStatus := range pod .Status .ContainerStatuses {
175
- if containerStatus .State .Waiting != nil {
176
- numWaiting ++
177
- } else if containerStatus .State .Running != nil {
175
+ if containerStatus .State .Running != nil {
178
176
if containerStatus .Ready {
179
177
numRunning ++
180
178
} else {
@@ -199,7 +197,8 @@ func GetPodStatus(pod *kcore.Pod) PodStatus {
199
197
numFailed ++
200
198
}
201
199
} else {
202
- return PodStatusUnknown
200
+ // either containerStatus.State.Waiting != nil or all containerStatus.States are nil (which implies waiting)
201
+ numWaiting ++
203
202
}
204
203
}
205
204
if numKilled > 0 {
You can’t perform that action at this time.
0 commit comments