Skip to content

Commit 28af029

Browse files
committed
Do not show terminated pods
1 parent ec45f4f commit 28af029

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,3 +60,7 @@ istio-system 70m 2140m 14800m 570Mi 3641Mi 8934Mi
6060
kube-system 82m 1831m 3222m 1312Mi 1203Mi 2365Mi
6161
155m 4081m 20122m 1912Mi 4989Mi 12452Mi
6262
```
63+
64+
## Known Issues
65+
66+
While init containers [play a role in resource allocation](https://kubernetes.io/docs/concepts/workloads/pods/init-containers/#resources), they are not accounted for in this tool.

pkg/client/client.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ func Run(args *model.Args) error {
3131
if err := runtime.DefaultUnstructuredConverter.FromUnstructured(info.Object.(*unstructured.Unstructured).Object, pm); err != nil {
3232
return nil
3333
}
34+
if pm.Status.Phase == v1.PodSucceeded || pm.Status.Phase == v1.PodFailed {
35+
return nil
36+
}
3437
responses = append(responses, fetchPod(pm))
3538
}
3639
return nil

0 commit comments

Comments
 (0)