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

NAME

6       kubectl rolling-update - Perform a rolling update. This command is dep‐
7       recated, use rollout instead.
8
9
10

SYNOPSIS

12       kubectl rolling-update [OPTIONS]
13
14
15

DESCRIPTION

17       Perform a rolling update of the given ReplicationController.
18
19
20       Replaces the specified replication controller with  a  new  replication
21       controller  by  updating  one pod at a time to use the new PodTemplate.
22       The new-controller.json must specify the same namespace as the existing
23       replication controller and overwrite at least one (common) label in its
24       replicaSelector.
25
26
27       !  ⟨http://kubernetes.io/images/docs/kubectl_rollingupdate.svg
28
29
30

OPTIONS

32       --allow-missing-template-keys=true
33           If true, ignore any errors in templates when a field or map key  is
34       missing  in  the  template.  Only applies to golang and jsonpath output
35       formats.
36
37
38       --container=""
39           Container name which will have its image  upgraded.  Only  relevant
40       when  --image  is  specified,  ignored  otherwise.  Required when using
41       --image on a multi-container pod
42
43
44       --deployment-label-key="deployment"
45           The key to use to differentiate between two different  controllers,
46       default 'deployment'.  Only relevant when --image is specified, ignored
47       otherwise
48
49
50       --dry-run=false
51           If true, only print the object that would be sent, without  sending
52       it.
53
54
55       -f, --filename=[]
56           Filename  or  URL to file to use to create the new replication con‐
57       troller.
58
59
60       --image=""
61           Image to use for upgrading the replication controller. Must be dis‐
62       tinct from the existing image (either new image or new image tag).  Can
63       not be used with --filename/-f
64
65
66       --image-pull-policy=""
67           Explicit policy for when to pull container  images.  Required  when
68       --image is same as existing image, ignored otherwise.
69
70
71       -o, --output=""
72           Output  format. One of: json|yaml|name|template|go-template|go-tem‐
73       plate-file|templatefile|jsonpath|jsonpath-file.
74
75
76       --poll-interval=3s
77           Time delay between polling for replication controller status  after
78       the  update. Valid time units are "ns", "us" (or "µs"), "ms", "s", "m",
79       "h".
80
81
82       --rollback=false
83           If true, this is a request to abort an  existing  rollout  that  is
84       partially rolled out. It effectively reverses current and next and runs
85       a rollout
86
87
88       --template=""
89           Template string or path to template file  to  use  when  -o=go-tem‐
90       plate,  -o=go-template-file.  The template format is golang templates [
91http://golang.org/pkg/text/template/#pkg-overview⟩].
92
93
94       --timeout=5m0s
95           Max time to wait for a replication controller to update before giv‐
96       ing up. Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h".
97
98
99       --update-period=1m0s
100           Time to wait between updating pods. Valid time units are "ns", "us"
101       (or "µs"), "ms", "s", "m", "h".
102
103
104       --validate=true
105           If true, use a schema to validate the input before sending it
106
107
108

OPTIONS INHERITED FROM PARENT COMMANDS

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

EXAMPLE

371                # Update pods of frontend-v1 using new replication controller data in frontend-v2.json.
372                kubectl rolling-update frontend-v1 -f frontend-v2.json
373
374                # Update pods of frontend-v1 using JSON data passed into stdin.
375                cat frontend-v2.json | kubectl rolling-update frontend-v1 -f -
376
377                # Update the pods of frontend-v1 to frontend-v2 by just changing the image, and switching the
378                # name of the replication controller.
379                kubectl rolling-update frontend-v1 frontend-v2 --image=image:v2
380
381                # Update the pods of frontend by just changing the image, and keeping the old name.
382                kubectl rolling-update frontend --image=image:v2
383
384                # Abort and reverse an existing rollout in progress (from frontend-v1 to frontend-v2).
385                kubectl rolling-update frontend-v1 frontend-v2 --rollback
386
387
388
389

SEE ALSO

391       kubectl(1),
392
393
394

HISTORY

396       January 2015, Originally compiled by Eric Paris (eparis at  redhat  dot
397       com)  based  on the kubernetes source material, but hopefully they have
398       been automatically generated since!
399
400
401
402Eric Paris                  kubernetes User Manuals              KUBERNETES(1)
Impressum