mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-29 21:29:24 +00:00
direct people to api-reference/definitions.html to find out if a field is mutable through kubectl replace/patch
This commit is contained in:
@@ -18,6 +18,10 @@ Update field(s) of a resource using strategic merge patch
|
||||
.PP
|
||||
JSON and YAML formats are accepted.
|
||||
|
||||
.PP
|
||||
Please refer to the models in
|
||||
\[la]https://htmlpreview.github.io/?https://github.com/GoogleCloudPlatform/kubernetes/HEAD/docs/api-reference/definitions.html\[ra] to find if a field is mutable.
|
||||
|
||||
|
||||
.SH OPTIONS
|
||||
.PP
|
||||
@@ -140,6 +144,9 @@ JSON and YAML formats are accepted.
|
||||
// Partially update a node using strategic merge patch
|
||||
kubectl patch node k8s\-node\-1 \-p '{"spec":{"unschedulable":true}}'
|
||||
|
||||
// Update a container's image; spec.containers[*].name is required because it's a merge key
|
||||
kubectl patch pod valid\-pod \-p '{"spec":{"containers":[{"name":"kubernetes\-serve\-hostname","image":"new image"}]}}'
|
||||
|
||||
.fi
|
||||
.RE
|
||||
|
||||
|
||||
@@ -18,6 +18,10 @@ Replace a resource by filename or stdin.
|
||||
.PP
|
||||
JSON and YAML formats are accepted.
|
||||
|
||||
.PP
|
||||
Please refer to the models in
|
||||
\[la]https://htmlpreview.github.io/?https://github.com/GoogleCloudPlatform/kubernetes/HEAD/docs/api-reference/definitions.html\[ra] to find if a field is mutable.
|
||||
|
||||
|
||||
.SH OPTIONS
|
||||
.PP
|
||||
|
||||
Reference in New Issue
Block a user