1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-03-07 08:26:53 +00:00
kyverno/test/policy/validate/check_registries.yaml

23 lines
496 B
YAML
Raw Normal View History

2019-11-13 13:56:20 -08:00
apiVersion : kyverno.io/v1
kind: ClusterPolicy
2019-07-17 13:31:00 -07:00
metadata:
name: check-registries
spec:
rules:
- name: check-registries
2019-07-25 14:57:44 -04:00
match:
resources:
kinds:
- Deployment
- StatefulSet
2019-07-17 13:31:00 -07:00
validate:
message: "Registry is not allowed"
pattern:
spec:
template:
spec:
containers:
- name: "*"
# Check allowed registries
2019-10-14 12:36:19 -07:00
image: "*/nirmata/* | https://private.registry.io/*"