1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-03-06 07:57:07 +00:00
kyverno/examples/Endpoints/policy-endpoints.yaml
2019-03-19 14:06:12 +02:00

25 lines
No EOL
545 B
YAML

apiVersion : policy.nirmata.io/v1alpha1
kind : Policy
metadata :
name : policy-endpoints
spec :
failurePolicy: stopOnError
rules:
- resource:
kind : Endpoints
selector:
matchLabels:
label : test
patch:
- path : "/subsets/0/ports/0/port"
op : replace
value: 9663
- path : "/subsets/0"
op: add
value:
addresses:
- ip: "192.168.10.171"
ports:
- name: load-balancer-connection
port: 80
protocol: UDP