This repo contains some examples for the new Validating Admission Policy feature for Kubernetes.
All examples in this repository can be tested with kind:
kind create cluster --config cluster.yaml
To clean up:
kind delete cluster
- basic - a simple example policy
- resource-filters - an example for matching many resources for the policy check and filtering out those we don't want to check
- multiple-validations - an example policy containing multiple validation
- message-expressions - an example policy containing multiple validations that have a human readable message returned to the client in case of failure
- parameters - an example of a parameterized policy