File tree Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Original file line number Diff line number Diff line change 4
4
> Create and update resources in a cluster.
5
5
> More information: < https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#apply > .
6
6
7
- - Apply a configuration to a resource by file name or ` stdin ` :
7
+ - Apply a configuration to a resource by file name:
8
8
9
- ` kubectl apply {{[-f|--filename]}} {{resource_filename}} `
9
+ ` kubectl apply {{[-f|--filename]}} {{path/to/filename}} `
10
+
11
+ - Apply a configuration to a resource from ` kustomization.yaml ` in a directory:
12
+
13
+ ` kubectl apply {{[-k|--kustomize]}} {{path/to/directory}} `
14
+
15
+ - Apply a configuration to a resource by ` stdin ` :
16
+
17
+ ` {{cat pod.json}} | kubectl apply {{[-f|--filename]}} - `
10
18
11
19
- Edit the latest last-applied-configuration annotations of resources from the default editor:
12
20
13
- ` kubectl apply edit-last-applied {{[-f|--filename]}} {{resource_filename }} `
21
+ ` kubectl apply edit-last-applied {{[-f|--filename]}} {{path/to/filename }} `
14
22
15
23
- Set the latest last-applied-configuration annotations by setting it to match the contents of a file:
16
24
17
- ` kubectl apply set-last-applied {{[-f|--filename]}} {{resource_filename }} `
25
+ ` kubectl apply set-last-applied {{[-f|--filename]}} {{path/to/filename }} `
18
26
19
27
- View the latest last-applied-configuration annotations by type/name or file:
20
28
21
- ` kubectl apply view-last-applied {{[-f|--filename]}} {{resource_filename }} `
29
+ ` kubectl apply view-last-applied {{[-f|--filename]}} {{path/to/filename }} `
You can’t perform that action at this time.
0 commit comments