mirror of
https://github.com/kyverno/kyverno.git
synced 2024-12-14 11:57:48 +00:00
b7bf894fe9
Signed-off-by: Mariam Fahmy <mariam.fahmy@nirmata.com>
21 lines
428 B
YAML
21 lines
428 B
YAML
apiVersion: kyverno.io/v2
|
|
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
|