KUBERNETES(1)(kubernetes) KUBERNETES(1)(kubernetes) Eric Paris Jan 2015 (NAME) kubectl-wait - (SYNOPSIS) kubectl wait [OPTIONS] (DESCRIPTION) . Status . "create" "delete" --for . (stdout) . -o . (OPTIONS) --all=false -A, --all-namespaces=false . (context) --namespace . --allow-missing-template-keys=true true . golang jsonpath . --field-selector="" ( ) '=', '==' '!=' ( --field-selector key1=value1,key2=value2). . -f, --filename=[] . --for=[] : [create|delete|condition=condition-name[=condition- value]|jsonpath='{JSONPath expression}'=[JSONPath value]]. condition-value true . (case folding) . AND . --for=create . --local=false true api-server . -o, --output="" . : (json, yaml, kyaml, name, go-template, go-template-file, template, templatefile, jsonpath, jsonpath-as-json, jsonpath-file). -R, --recursive=true -f, --filename. . -l, --selector="" ( ) '=', '==' '!=' ( -l key1=value1,key2=value2). --show-managed-fields=false true JSON YAML (managedFields) . --template="" -o=go-template -o=go-template-file. golang [http://golang.org/pkg/text/template/#pkg-overview]. --timeout=30s . . (OPTIONS INHERITED FROM PARENT COMMANDS) --as="" (impersonate) . (service account) . --as-group=[] . --as-uid="" (UID) . --as-user-extra=[] . --cache-dir="/home/username/.kube/cache" --certificate-authority="" (CA) --client-certificate="" TLS --client-key="" TLS --cluster="" kubeconfig --context="" (context) kubeconfig --disable-compression=false true --insecure-skip-tls-verify=false true . HTTPS --kubeconfig="" kubeconfig CLI. --kuberc="" kuberc . feature gate KUBECTL_KUBERC=false KUBERC=off . --match-server-version=false -n, --namespace="" CLI --password="" API --profile="none" . : (none|cpu|heap|goroutine|threadcreate|block|mutex|trace) --profile-output="profile.pprof" --request-timeout="0" . ( 1s 2m 3h). . -s, --server="" API --tls-server-name="" . --token="" (Bearer token) API --user="" kubeconfig --username="" API --version=false --version --version=raw --version=vX.Y.Z... --warnings-as-errors=false (EXAMPLES) # "busybox1" "Ready" kubectl wait --for=condition=Ready pod/busybox1 # true ( ) kubectl wait --for=condition=Ready=false pod/busybox1 # "busybox1" "Running" kubectl wait --for=jsonpath='{.status.phase}'=Running pod/busybox1 # "busybox1" (Ready) kubectl wait --for='jsonpath={.status.conditions[?(@.type=="Ready")].status}=True' pod/busybox1 # (ingress) "loadbalancer" kubectl wait --for=jsonpath='{.status.loadBalancer.ingress}' service/loadbalancer # "busybox1" kubectl create secret generic busybox1 kubectl wait --for=create secret/busybox1 --timeout=30s # "busybox1" "delete" kubectl delete pod/busybox1 kubectl wait --for=delete pod/busybox1 --timeout=60s # "busybox1" "Ready" kubectl wait --for=condition=Ready --for=create pod/busybox1 # "busybox1" "Ready" "False" until kubectl wait pod/busybox1 --for=condition=Ready --timeout=1s 2>/dev/null || \ kubectl wait pod/busybox1 --for=condition=ContainersReady=False --timeout=1s 2>/dev/null; \ do echo "Checking conditions..."; sleep 1; done (SEE ALSO) kubectl(1) (HISTORY) (eparis at redhat dot com) ! Manuals User KUBERNETES(1)(kubernetes)