1KUBERNETES(1) Jan 2015 KUBERNETES(1)
2
3
4
6 kubectl apply view-last-applied - View latest last-applied-configura‐
7 tion annotations of a resource/object
8
9
10
12 kubectl apply view-last-applied [OPTIONS]
13
14
15
17 View the latest last-applied-configuration annotations by type/name or
18 file.
19
20
21 The default output will be printed to stdout in YAML format. One can
22 use -o option to change output format.
23
24
25
27 --all=false
28 Select all resources in the namespace of the specified resource
29 types
30
31
32 -f, --filename=[]
33 Filename, directory, or URL to files that contains the
34 last-applied-configuration annotations
35
36
37 -k, --kustomize=""
38 Process the kustomization directory. This flag can't be used
39 together with -f or -R.
40
41
42 -o, --output="yaml"
43 Output format. Must be one of yaml|json
44
45
46 -R, --recursive=false
47 Process the directory used in -f, --filename recursively. Useful
48 when you want to manage related manifests organized within the same
49 directory.
50
51
52 -l, --selector=""
53 Selector (label query) to filter on, supports '=', '==', and
54 '!='.(e.g. -l key1=value1,key2=value2)
55
56
57
59 --alsologtostderr=false
60 log to standard error as well as files
61
62
63 --application-metrics-count-limit=100
64 Max number of application metrics to store (per container)
65
66
67 --as=""
68 Username to impersonate for the operation
69
70
71 --as-group=[]
72 Group to impersonate for the operation, this flag can be repeated
73 to specify multiple groups.
74
75
76 --azure-container-registry-config=""
77 Path to the file containing Azure container registry configuration
78 information.
79
80
81 --boot-id-file="/proc/sys/kernel/random/boot_id"
82 Comma-separated list of files to check for boot-id. Use the first
83 one that exists.
84
85
86 --cache-dir="/builddir/.kube/http-cache"
87 Default HTTP cache directory
88
89
90 --certificate-authority=""
91 Path to a cert file for the certificate authority
92
93
94 --client-certificate=""
95 Path to a client certificate file for TLS
96
97
98 --client-key=""
99 Path to a client key file for TLS
100
101
102 --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
103 CIDRs opened in GCE firewall for LB traffic proxy health checks
104
105
106 --cluster=""
107 The name of the kubeconfig cluster to use
108
109
110 --container-hints="/etc/cadvisor/container_hints.json"
111 location of the container hints file
112
113
114 --containerd="/run/containerd/containerd.sock"
115 containerd endpoint
116
117
118 --containerd-namespace="k8s.io"
119 containerd namespace
120
121
122 --context=""
123 The name of the kubeconfig context to use
124
125
126 --default-not-ready-toleration-seconds=300
127 Indicates the tolerationSeconds of the toleration for
128 notReady:NoExecute that is added by default to every pod that does not
129 already have such a toleration.
130
131
132 --default-unreachable-toleration-seconds=300
133 Indicates the tolerationSeconds of the toleration for unreach‐
134 able:NoExecute that is added by default to every pod that does not
135 already have such a toleration.
136
137
138 --docker="unix:///var/run/docker.sock"
139 docker endpoint
140
141
142 --docker-env-metadata-whitelist=""
143 a comma-separated list of environment variable keys that needs to
144 be collected for docker containers
145
146
147 --docker-only=false
148 Only report docker containers in addition to root stats
149
150
151 --docker-root="/var/lib/docker"
152 DEPRECATED: docker root is read from docker info (this is a fall‐
153 back, default: /var/lib/docker)
154
155
156 --docker-tls=false
157 use TLS to connect to docker
158
159
160 --docker-tls-ca="ca.pem"
161 path to trusted CA
162
163
164 --docker-tls-cert="cert.pem"
165 path to client certificate
166
167
168 --docker-tls-key="key.pem"
169 path to private key
170
171
172 --enable-load-reader=false
173 Whether to enable cpu load reader
174
175
176 --event-storage-age-limit="default=0"
177 Max length of time for which to store events (per type). Value is a
178 comma separated list of key values, where the keys are event types
179 (e.g.: creation, oom) or "default" and the value is a duration. Default
180 is applied to all non-specified event types
181
182
183 --event-storage-event-limit="default=0"
184 Max number of events to store (per type). Value is a comma sepa‐
185 rated list of key values, where the keys are event types (e.g.: cre‐
186 ation, oom) or "default" and the value is an integer. Default is
187 applied to all non-specified event types
188
189
190 --global-housekeeping-interval=1m0s
191 Interval between global housekeepings
192
193
194 --housekeeping-interval=10s
195 Interval between container housekeepings
196
197
198 --insecure-skip-tls-verify=false
199 If true, the server's certificate will not be checked for validity.
200 This will make your HTTPS connections insecure
201
202
203 --kubeconfig=""
204 Path to the kubeconfig file to use for CLI requests.
205
206
207 --log-backtrace-at=:0
208 when logging hits line file:N, emit a stack trace
209
210
211 --log-cadvisor-usage=false
212 Whether to log the usage of the cAdvisor container
213
214
215 --log-dir=""
216 If non-empty, write log files in this directory
217
218
219 --log-file=""
220 If non-empty, use this log file
221
222
223 --log-file-max-size=1800
224 Defines the maximum size a log file can grow to. Unit is megabytes.
225 If the value is 0, the maximum file size is unlimited.
226
227
228 --log-flush-frequency=5s
229 Maximum number of seconds between log flushes
230
231
232 --logtostderr=true
233 log to standard error instead of files
234
235
236 --machine-id-file="/etc/machine-id,/var/lib/dbus/machine-id"
237 Comma-separated list of files to check for machine-id. Use the
238 first one that exists.
239
240
241 --match-server-version=false
242 Require server version to match client version
243
244
245 -n, --namespace=""
246 If present, the namespace scope for this CLI request
247
248
249 --password=""
250 Password for basic authentication to the API server
251
252
253 --profile="none"
254 Name of profile to capture. One of (none|cpu|heap|goroutine|thread‐
255 create|block|mutex)
256
257
258 --profile-output="profile.pprof"
259 Name of the file to write the profile to
260
261
262 --request-timeout="0"
263 The length of time to wait before giving up on a single server
264 request. Non-zero values should contain a corresponding time unit (e.g.
265 1s, 2m, 3h). A value of zero means don't timeout requests.
266
267
268 -s, --server=""
269 The address and port of the Kubernetes API server
270
271
272 --skip-headers=false
273 If true, avoid header prefixes in the log messages
274
275
276 --skip-log-headers=false
277 If true, avoid headers when opening log files
278
279
280 --stderrthreshold=2
281 logs at or above this threshold go to stderr
282
283
284 --storage-driver-buffer-duration=1m0s
285 Writes in the storage driver will be buffered for this duration,
286 and committed to the non memory backends as a single transaction
287
288
289 --storage-driver-db="cadvisor"
290 database name
291
292
293 --storage-driver-host="localhost:8086"
294 database host:port
295
296
297 --storage-driver-password="root"
298 database password
299
300
301 --storage-driver-secure=false
302 use secure connection with database
303
304
305 --storage-driver-table="stats"
306 table name
307
308
309 --storage-driver-user="root"
310 database username
311
312
313 --token=""
314 Bearer token for authentication to the API server
315
316
317 --update-machine-info-interval=5m0s
318 Interval between machine info updates.
319
320
321 --user=""
322 The name of the kubeconfig user to use
323
324
325 --username=""
326 Username for basic authentication to the API server
327
328
329 -v, --v=0
330 number for the log level verbosity
331
332
333 --version=false
334 Print version information and quit
335
336
337 --vmodule=
338 comma-separated list of pattern=N settings for file-filtered log‐
339 ging
340
341
342
344 # View the last-applied-configuration annotations by type/name in YAML.
345 kubectl apply view-last-applied deployment/nginx
346
347 # View the last-applied-configuration annotations by file in JSON
348 kubectl apply view-last-applied -f deploy.yaml -o json
349
350
351
352
354 kubectl-apply(1),
355
356
357
359 January 2015, Originally compiled by Eric Paris (eparis at redhat dot
360 com) based on the kubernetes source material, but hopefully they have
361 been automatically generated since!
362
363
364
365Eric Paris kubernetes User Manuals KUBERNETES(1)