1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2024-12-14 11:57:48 +00:00
kyverno/test/conformance/chainsaw/exceptions/with-wildcard/policy.yaml
Mariam Fahmy 2140a0239b
chore: rename validationFailureAction to failureAction under the rule (#10893)
Signed-off-by: Mariam Fahmy <mariam.fahmy@nirmata.com>
Co-authored-by: Jim Bugwadia <jim@nirmata.com>
2024-08-27 20:07:57 +00:00

20 lines
420 B
YAML

apiVersion: kyverno.io/v2beta1
kind: ClusterPolicy
metadata:
name: require-labels
spec:
background: false
rules:
- name: require-team
match:
any:
- resources:
kinds:
- ConfigMap
validate:
failureAction: Enforce
message: 'The label `team` is required.'
pattern:
metadata:
labels:
team: '?*'