Skip to content

Commit b62995a

Browse files
committed
Add a ValidatingAdmissionPolicy blocking ServiceCIDR changes
OCP does not yet support changing the service CIDRs at runtime.
1 parent de93ea6 commit b62995a

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
apiVersion: admissionregistration.k8s.io/v1
2+
kind: ValidatingAdmissionPolicy
3+
metadata:
4+
name: "servicecidrs.openshift.io"
5+
spec:
6+
failurePolicy: Fail
7+
matchConstraints:
8+
resourceRules:
9+
- apiGroups: ["networking"]
10+
apiVersions: ["v1"]
11+
operations: ["CREATE", "UPDATE"]
12+
resources: ["servicecidr"]
13+
validations:
14+
- expression: "object.name != 'kubernetes'"

0 commit comments

Comments
 (0)