Konubinix' opinionated web of thoughts

How to Wait for a Kubernetes Pod to Be Ready

Fleeting

How to wait for a Kubernetes pod to be ready — one liner | by Reuven Harrison | Medium

while [[ $(kubectl get pods hello-d8d8d7455-j9nzw -o ‘jsonpath={..status.conditions[?(@.type==“Ready”)].status}’) != “True” ]]; do echo “waiting for pod” && sleep 1; done By label (deployment): while [[ $(kubectl get pods -l app=hello -o ‘jsonpath={..status.conditions[?(@.type==“Ready”)].status}’) != “True” ]]; do echo “waiting for pod” && sleep 1; done