1KUBERNETES(1)                      Jan 2015                      KUBERNETES(1)
2
3
4

NAME

6       kubectl  wait  -  Experimental: Wait for a specific condition on one or
7       many resources.
8
9
10

SYNOPSIS

12       kubectl wait [OPTIONS]
13
14
15

DESCRIPTION

17       Experimental: Wait for a specific condition on one or many resources.
18
19
20       The command takes multiple resources and waits until the specified con‐
21       dition is seen in the Status field of every given resource.
22
23
24       Alternatively,  the  command can wait for the given set of resources to
25       be deleted by providing the "delete" keyword as the value to the  --for
26       flag.
27
28
29       A  successful  message  will  be  printed to stdout indicating when the
30       specified condition has been met. One can use -o option  to  change  to
31       output destination.
32
33
34

OPTIONS

36       --all-namespaces=false
37           If  present,  list  the  requested object(s) across all namespaces.
38       Namespace in current context is ignored even if specified with --names‐
39       pace.
40
41
42       --allow-missing-template-keys=true
43           If  true, ignore any errors in templates when a field or map key is
44       missing in the template. Only applies to  golang  and  jsonpath  output
45       formats.
46
47
48       -f, --filename=[]
49           identifying the resource.
50
51
52       --for=""
53           The condition to wait on: [delete|condition=condition-name].
54
55
56       -o, --output=""
57           Output    format.    One   of:   json|yaml|name|go-template|go-tem‐
58       plate-file|templatefile|template|jsonpath|jsonpath-file.
59
60
61       -R, --recursive=true
62           Process the directory used in -f,  --filename  recursively.  Useful
63       when  you  want  to  manage related manifests organized within the same
64       directory.
65
66
67       -l, --selector=""
68           Selector (label query)  to  filter  on,  supports  '=',  '==',  and
69       '!='.(e.g. -l key1=value1,key2=value2)
70
71
72       --template=""
73           Template  string  or  path  to template file to use when -o=go-tem‐
74       plate, -o=go-template-file. The template format is golang  templates  [
75http://golang.org/pkg/text/template/#pkg-overview⟩].
76
77
78       --timeout=30s
79           The length of time to wait before giving up.  Zero means check once
80       and don't wait, negative means wait for a week.
81
82
83

OPTIONS INHERITED FROM PARENT COMMANDS

85       --allow-verification-with-non-compliant-keys=false
86           Allow  a  SignatureVerifier  to  use  keys  which  are  technically
87       non-compliant with RFC6962.
88
89
90       --alsologtostderr=false
91           log to standard error as well as files
92
93
94       --application-metrics-count-limit=100
95           Max number of application metrics to store (per container)
96
97
98       --as=""
99           Username to impersonate for the operation
100
101
102       --as-group=[]
103           Group  to  impersonate for the operation, this flag can be repeated
104       to specify multiple groups.
105
106
107       --azure-container-registry-config=""
108           Path to the file containing Azure container registry  configuration
109       information.
110
111
112       --boot-id-file="/proc/sys/kernel/random/boot_id"
113           Comma-separated  list  of files to check for boot-id. Use the first
114       one that exists.
115
116
117       --cache-dir="/builddir/.kube/http-cache"
118           Default HTTP cache directory
119
120
121       --certificate-authority=""
122           Path to a cert file for the certificate authority
123
124
125       --client-certificate=""
126           Path to a client certificate file for TLS
127
128
129       --client-key=""
130           Path to a client key file for TLS
131
132
133       --cloud-provider-gce-lb-src-cidrs=130.211.0.0/22,209.85.152.0/22,209.85.204.0/22,35.191.0.0/16
134           CIDRs opened in GCE firewall for LB traffic proxy  health checks
135
136
137       --cluster=""
138           The name of the kubeconfig cluster to use
139
140
141       --container-hints="/etc/cadvisor/container_hints.json"
142           location of the container hints file
143
144
145       --containerd="unix:///var/run/containerd.sock"
146           containerd endpoint
147
148
149       --context=""
150           The name of the kubeconfig context to use
151
152
153       --default-not-ready-toleration-seconds=300
154           Indicates    the    tolerationSeconds   of   the   toleration   for
155       notReady:NoExecute that is added by default to every pod that does  not
156       already have such a toleration.
157
158
159       --default-unreachable-toleration-seconds=300
160           Indicates  the  tolerationSeconds  of  the  toleration for unreach‐
161       able:NoExecute that is added by default to  every  pod  that  does  not
162       already have such a toleration.
163
164
165       --docker="unix:///var/run/docker.sock"
166           docker endpoint
167
168
169       --docker-env-metadata-whitelist=""
170           a  comma-separated  list of environment variable keys that needs to
171       be collected for docker containers
172
173
174       --docker-only=false
175           Only report docker containers in addition to root stats
176
177
178       --docker-root="/var/lib/docker"
179           DEPRECATED: docker root is read from docker info (this is  a  fall‐
180       back, default: /var/lib/docker)
181
182
183       --docker-tls=false
184           use TLS to connect to docker
185
186
187       --docker-tls-ca="ca.pem"
188           path to trusted CA
189
190
191       --docker-tls-cert="cert.pem"
192           path to client certificate
193
194
195       --docker-tls-key="key.pem"
196           path to private key
197
198
199       --enable-load-reader=false
200           Whether to enable cpu load reader
201
202
203       --event-storage-age-limit="default=0"
204           Max length of time for which to store events (per type). Value is a
205       comma separated list of key values, where  the  keys  are  event  types
206       (e.g.: creation, oom) or "default" and the value is a duration. Default
207       is applied to all non-specified event types
208
209
210       --event-storage-event-limit="default=0"
211           Max number of events to store (per type). Value is  a  comma  sepa‐
212       rated  list  of  key values, where the keys are event types (e.g.: cre‐
213       ation, oom) or "default" and  the  value  is  an  integer.  Default  is
214       applied to all non-specified event types
215
216
217       --global-housekeeping-interval=1m0s
218           Interval between global housekeepings
219
220
221       --google-json-key=""
222           The  Google  Cloud  Platform  Service  Account  JSON Key to use for
223       authentication.
224
225
226       --housekeeping-interval=10s
227           Interval between container housekeepings
228
229
230       --insecure-skip-tls-verify=false
231           If true, the server's certificate will not be checked for validity.
232       This will make your HTTPS connections insecure
233
234
235       --kubeconfig=""
236           Path to the kubeconfig file to use for CLI requests.
237
238
239       --log-backtrace-at=:0
240           when logging hits line file:N, emit a stack trace
241
242
243       --log-cadvisor-usage=false
244           Whether to log the usage of the cAdvisor container
245
246
247       --log-dir=""
248           If non-empty, write log files in this directory
249
250
251       --log-flush-frequency=5s
252           Maximum number of seconds between log flushes
253
254
255       --logtostderr=true
256           log to standard error instead of files
257
258
259       --machine-id-file="/etc/machine-id,/var/lib/dbus/machine-id"
260           Comma-separated  list  of  files  to  check for machine-id. Use the
261       first one that exists.
262
263
264       --match-server-version=false
265           Require server version to match client version
266
267
268       --mesos-agent="127.0.0.1:5051"
269           Mesos agent address
270
271
272       --mesos-agent-timeout=10s
273           Mesos agent timeout
274
275
276       -n, --namespace=""
277           If present, the namespace scope for this CLI request
278
279
280       --request-timeout="0"
281           The length of time to wait before giving  up  on  a  single  server
282       request. Non-zero values should contain a corresponding time unit (e.g.
283       1s, 2m, 3h). A value of zero means don't timeout requests.
284
285
286       -s, --server=""
287           The address and port of the Kubernetes API server
288
289
290       --stderrthreshold=2
291           logs at or above this threshold go to stderr
292
293
294       --storage-driver-buffer-duration=1m0s
295           Writes in the storage driver will be buffered  for  this  duration,
296       and committed to the non memory backends as a single transaction
297
298
299       --storage-driver-db="cadvisor"
300           database name
301
302
303       --storage-driver-host="localhost:8086"
304           database host:port
305
306
307       --storage-driver-password="root"
308           database password
309
310
311       --storage-driver-secure=false
312           use secure connection with database
313
314
315       --storage-driver-table="stats"
316           table name
317
318
319       --storage-driver-user="root"
320           database username
321
322
323       --token=""
324           Bearer token for authentication to the API server
325
326
327       --user=""
328           The name of the kubeconfig user to use
329
330
331       -v, --v=0
332           log level for V logs
333
334
335       --version=false
336           Print version information and quit
337
338
339       --vmodule=
340           comma-separated  list  of pattern=N settings for file-filtered log‐
341       ging
342
343
344

EXAMPLE

346                # Wait for the pod "busybox1" to contain the status condition of type "Ready".
347                kubectl wait --for=condition=Ready pod/busybox1
348
349                # Wait for the pod "busybox1" to be deleted, with a timeout of 60s, after having issued the "delete" command.
350                kubectl delete pod/busybox1
351                kubectl wait --for=delete pod/busybox1 --timeout=60s
352
353
354
355

SEE ALSO

357       kubectl(1),
358
359
360

HISTORY

362       January 2015, Originally compiled by Eric Paris (eparis at  redhat  dot
363       com)  based  on the kubernetes source material, but hopefully they have
364       been automatically generated since!
365
366
367
368Eric Paris                  kubernetes User Manuals              KUBERNETES(1)
Impressum