1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-03-06 16:06:56 +00:00
kyverno/examples/policy_mutate_endpoint.yaml

22 lines
479 B
YAML
Raw Normal View History

2019-05-22 20:07:41 -07:00
apiVersion : kyverno.io/v1alpha1
kind : Policy
metadata :
name : policy-endpoints
spec :
rules:
- name: pEP
2019-07-25 14:57:44 -04:00
match:
resources:
kinds :
- Endpoints
selector:
matchLabels:
label : test
2019-05-22 20:07:41 -07:00
mutate:
patches:
- path : "/subsets/0/ports/0/port"
op : replace
value: 9663
2019-07-29 19:01:17 -07:00
- path : "/metadata/labels/isMutated"
2019-05-22 20:07:41 -07:00
op: add
2019-07-29 19:01:17 -07:00
value: "true"