1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-03-13 03:16:55 +00:00
kyverno/test/conformance/manifests/should-fail/background-userinfo-2.yaml
Charles-Edouard Brétéché ad2cbd3b33
feat: add simple conformance tests (#5073)
* feat: add simple conformance tests
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
Co-authored-by: Vyankatesh Kudtarkar <vyankateshkd@gmail.com>
2022-10-20 12:17:33 +00:00

21 lines
436 B
YAML

apiVersion: kyverno.io/v1
kind: ClusterPolicy
metadata:
name: background-userinfo-2
spec:
validationFailureAction: audit
background: true
rules:
- name: ns-clusterroles-old
match:
resources:
kinds:
- Pod
clusterRoles:
- foo-admin
validate:
message: The `owner` label is required for all Namespaces.
pattern:
metadata:
labels:
owner: "?*"