Pods stuck in pending state Pods stuck in pending state kubernetes kubernetes

Pods stuck in pending state


Maybe a better way to check this is to have a loop and sleep inside to loop and continuously keep checking the status until all pods are up are running. I had done something similar to check if all the required pods were up by checking the status.But you might also want to consider adding the liveness and readiness probe on the pods before you make such a check. There are additional details provided here.

https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/


Not sure if this question is still open, but I would suggest to use something like this: https://github.com/kubernetes/helm/blob/d790f7d843182f1c126cfa64989ffdd4e9583747/pkg/kube/wait.go#L174

It loops through deployments, and wait till max available from manifest.