add CEL Playground link

This commit is contained in:
Matheus Moraes 2023-09-08 16:42:43 -03:00
parent 1de4c16bfe
commit c64c7837c8
No known key found for this signature in database
GPG Key ID: 42D780DF62C3314F
2 changed files with 8 additions and 0 deletions

View File

@ -67,6 +67,10 @@ The following is an example of a ValidatingAdmissionPolicy.
to validate the request. If an expression evaluates to false, the validation check is enforced
according to the `spec.failurePolicy` field.
{{< note >}}
You can quickly test CEL expressions in [CEL Playground](https://playcel.undistro.io).
{{< /note >}}
To configure a validating admission policy for use in a cluster, a binding is required.
The following is an example of a ValidatingAdmissionPolicyBinding.:

View File

@ -849,6 +849,10 @@ The CronTab "my-new-cron-object" is invalid:
* spec: Invalid value: map[string]interface {}{"maxReplicas":10, "minReplicas":0, "replicas":20}: failed rule: self.replicas <= self.maxReplicas
```
{{< note >}}
You can quickly test CEL expressions in [CEL Playground](https://playcel.undistro.io).
{{< /note >}}
Validation rules are compiled when CRDs are created/updated.
The request of CRDs create/update will fail if compilation of validation rules fail.
Compilation process includes type checking as well.