Add deprecation warning info
This commit is contained in:
@@ -628,6 +628,47 @@ So a webhook response to add that label would be:
|
||||
{{% /tab %}}
|
||||
{{< /tabs >}}
|
||||
|
||||
Starting in v1.19, admission webhooks can optionally return warning messages that are returned to the requesting client.
|
||||
Warnings can be sent with allowed or rejected admission responses.
|
||||
No "Warning:" prefix should be included in the message.
|
||||
Warning messages should describe a problem the client making the API request should correct or be aware of.
|
||||
Limit warnings to 120 characters if possible. Warnings over 256 characters and large numbers of warnings may be truncated.
|
||||
|
||||
{{< tabs name="AdmissionReview_response_warning" >}}
|
||||
{{% tab name="admission.k8s.io/v1" %}}
|
||||
```json
|
||||
{
|
||||
"apiVersion": "admission.k8s.io/v1",
|
||||
"kind": "AdmissionReview",
|
||||
"response": {
|
||||
"uid": "<value from request.uid>",
|
||||
"allowed": true,
|
||||
"warnings": [
|
||||
"duplicate envvar entries specified with name MY_ENV",
|
||||
"memory request less than 4MB specified for container mycontainer, which will not start successfully"
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
{{% /tab %}}
|
||||
{{% tab name="admission.k8s.io/v1beta1" %}}
|
||||
```json
|
||||
{
|
||||
"apiVersion": "admission.k8s.io/v1beta1",
|
||||
"kind": "AdmissionReview",
|
||||
"response": {
|
||||
"uid": "<value from request.uid>",
|
||||
"allowed": true,
|
||||
"warnings": [
|
||||
"duplicate envvar entries specified with name MY_ENV",
|
||||
"memory request less than 4MB specified for container mycontainer, which will not start successfully"
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
{{% /tab %}}
|
||||
{{< /tabs >}}
|
||||
|
||||
## Webhook configuration
|
||||
|
||||
To register admission webhooks, create `MutatingWebhookConfiguration` or `ValidatingWebhookConfiguration` API objects.
|
||||
|
||||
Reference in New Issue
Block a user