Skip to content

Commit 08bfcfc

Browse files
authored
Merge pull request kubernetes-sigs#1663 from vexxhost/feature/allow-update-openstackcluster-allowAllInClusterTraffic
✨Allow changing allowAllInClusterTraffic in a deployed cluster
2 parents 01b5263 + 30cd0da commit 08bfcfc

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

api/v1alpha7/openstackcluster_webhook.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,10 @@ func (r *OpenStackCluster) ValidateUpdate(oldRaw runtime.Object) (admission.Warn
130130
old.Spec.ControlPlaneAvailabilityZones = []string{}
131131
r.Spec.ControlPlaneAvailabilityZones = []string{}
132132

133+
// Allow change to the allowAllInClusterTraffic.
134+
old.Spec.AllowAllInClusterTraffic = false
135+
r.Spec.AllowAllInClusterTraffic = false
136+
133137
if !reflect.DeepEqual(old.Spec, r.Spec) {
134138
allErrs = append(allErrs, field.Forbidden(field.NewPath("spec"), "cannot be modified"))
135139
}

0 commit comments

Comments
 (0)