mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-09 09:26:54 +00:00
22 lines
433 B
YAML
22 lines
433 B
YAML
|
apiVersion: kyverno.io/v2beta1
|
||
|
kind: PolicyException
|
||
|
metadata:
|
||
|
name: failing-container-exception
|
||
|
spec:
|
||
|
exceptions:
|
||
|
- policyName: max-containers
|
||
|
ruleNames:
|
||
|
- max-two-containers
|
||
|
- autogen-max-two-containers
|
||
|
match:
|
||
|
any:
|
||
|
- resources:
|
||
|
kinds:
|
||
|
- Pod
|
||
|
- Deployment
|
||
|
conditions:
|
||
|
any:
|
||
|
- key: "{{ request.object.metadata.labels.color || '' }}"
|
||
|
operator: Equals
|
||
|
value: red
|