You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/zh-cn/docs/tasks/extend-kubernetes/custom-resources/custom-resource-definition-versioning.md
+13-15Lines changed: 13 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -73,8 +73,7 @@ Adding a new version:
73
73
74
74
1. Pick a conversion strategy. Since custom resource objects need the ability to
75
75
be served at both versions, that means they will sometimes be served in a
76
-
different version than the one stored. To make this possible, the custom
77
-
resource objects must sometimes be converted between the
76
+
different version than the one stored. To make this possible, the custom resource objects must sometimes be converted between the
78
77
version they are stored at and the version they are served at. If the
79
78
conversion involves schema changes and requires custom logic, a conversion
80
79
webhook should be used. If there are no schema changes, the default `None`
@@ -132,7 +131,7 @@ Removing an old version:
132
131
1. Set `served` to `false` for the old version in the `spec.versions` list. If
133
132
any clients are still unexpectedly using the old version they may begin reporting
134
133
errors attempting to access the custom resource objects at the old version.
135
-
If this occurs, switch back to using `served:true` on the old version, migrate the
134
+
If this occurs, switch back to using `served:true` on the old version, migrate the
136
135
remaining clients to the new version and repeat this step.
137
136
1. Ensure the [upgrade of existing objects to the new stored version](#upgrade-existing-objects-to-a-new-stored-version) step has been completed.
138
137
1. Verify that the `storage` is set to `true` for the new version in the `spec.versions` list in the CustomResourceDefinition.
@@ -532,9 +531,6 @@ spec:
532
531
533
532
<!--
534
533
## Webhook conversion
535
-
536
-
Webhook conversion is available as beta since 1.15, and as alpha since Kubernetes 1.13. The
537
-
`CustomResourceWebhookConversion`feature should be enabled. Please refer to the [feature gate](/docs/reference/command-line-tools-reference/feature-gates/) documentation for more information.
538
534
-->
539
535
## Webhook 转换 {#webhook-conversion}
540
536
@@ -627,7 +623,7 @@ how to [authenticate API servers](/docs/reference/access-authn-authz/extensible-
627
623
A conversion webhook must not mutate anything inside of `metadata` of the converted object
628
624
other than `labels` and `annotations`.
629
625
Attempted changes to `name`, `UID` and `namespace` are rejected and fail the request
630
-
which caused the conversion. All other changes are ignored.
626
+
which caused the conversion. All other changes are ignored.
631
627
-->
632
628
#### 被允许的变更
633
629
@@ -639,8 +635,10 @@ which caused the conversion. All other changes are ignored.
639
635
<!--
640
636
### Deploy the conversion webhook service
641
637
642
-
Documentation for deploying the conversion webhook is the same as for the [admission webhook example service](/docs/reference/access-authn-authz/extensible-admission-controllers/#deploy_the_admission_webhook_service).
643
-
The assumption for next sections is that the conversion webhook server is deployed to a service named `example-conversion-webhook-server` in `default` namespace and serving traffic on path `/crdconvert`.
638
+
Documentation for deploying the conversion webhook is the same as for the
639
+
[admission webhook example service](/docs/reference/access-authn-authz/extensible-admission-controllers/#deploy_the_admission_webhook_service).
640
+
The assumption for next sections is that the conversion webhook server is deployed to a service
641
+
named `example-conversion-webhook-server` in `default` namespace and serving traffic on path `/crdconvert`.
0 commit comments