Clean up admission controller deprecation example (#18399)

This commit is contained in:
Tim Bannister 2020-01-29 23:28:14 +00:00 committed by GitHub
parent c43b4a5dd5
commit 3cf7ba1092
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 3 deletions

View File

@ -969,9 +969,10 @@ Specifying `Equivalent` is recommended, and ensures that webhooks continue to in
resources they expect when upgrades enable new versions of the resource in the API server.
When a resource stops being served by the API server, it is no longer considered equivalent to other versions of that resource that are still served.
For example, deprecated `extensions/v1beta1` deployments are scheduled to stop being served by default in v1.16.
Once that occurs, a webhook with a `apiGroups:["extensions"], apiVersions:["v1beta1"], resources:["deployments"]` rule
would no longer intercept deployments created via `apps/v1` APIs. For that reason, webhooks should prefer registering
For example, `extensions/v1beta1` deployments were first deprecated and then removed (in Kubernetes v1.16).
Since that removal, a webhook with a `apiGroups:["extensions"], apiVersions:["v1beta1"], resources:["deployments"]` rule
does not intercept deployments created via `apps/v1` APIs. For that reason, webhooks should prefer registering
for stable versions of resources.
This example shows a validating webhook that intercepts modifications to deployments (no matter the API group or version),