mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-07 04:03:20 +00:00
Generate new docs with the new changes
This commit is contained in:
@@ -4,23 +4,27 @@ Update a resource by filename or stdin.
|
||||
|
||||
### Synopsis
|
||||
|
||||
```
|
||||
Update a resource by filename or stdin.
|
||||
|
||||
JSON and YAML formats are accepted.
|
||||
|
||||
Examples:
|
||||
|
||||
// Update a pod using the data in pod.json.
|
||||
$ kubectl update -f pod.json
|
||||
|
||||
// Update a pod based on the JSON passed into stdin.
|
||||
$ cat pod.json | kubectl update -f -
|
||||
|
||||
// Update a pod by downloading it, applying the patch, then updating. Requires apiVersion be specified.
|
||||
$ kubectl update pods my-pod --patch='{ "apiVersion": "v1beta1", "desiredState": { "manifest": [{ "cpu": 100 }]}}'
|
||||
```
|
||||
|
||||
kubectl update -f filename
|
||||
|
||||
### Examples
|
||||
|
||||
```
|
||||
// Update a pod using the data in pod.json.
|
||||
$ kubectl update -f pod.json
|
||||
|
||||
// Update a pod based on the JSON passed into stdin.
|
||||
$ cat pod.json | kubectl update -f -
|
||||
|
||||
// Update a pod by downloading it, applying the patch, then updating. Requires apiVersion be specified.
|
||||
$ kubectl update pods my-pod --patch='{ "apiVersion": "v1beta1", "desiredState": { "manifest": [{ "cpu": 100 }]}}'
|
||||
```
|
||||
|
||||
### Options
|
||||
|
||||
```
|
||||
|
Reference in New Issue
Block a user