kubernetes-sigs / cluster-api-provider-openstack

Cluster API implementation for OpenStack
https://cluster-api-openstack.sigs.k8s.io/
Apache License 2.0
275 stars 253 forks source link

spec.floatingIPNetwork in OpenStackFloatingIPPool no longer optional #1997

Closed huxcrux closed 3 months ago

huxcrux commented 3 months ago

/kind bug

What steps did you take and what happened: When reading the API spec floatingIPNetwork is listed as optional (https://github.com/kubernetes-sigs/cluster-api-provider-openstack/blob/main/api/v1alpha1/openstackfloatingippool_types.go#L64-L66)

If I use 0.10.0-alpha.0 and not setting floatingIPNetwork i get the following error:

"error": "[OpenStackFloatingIPPool.infrastructure.cluster.x-k8s.io](http://openstackfloatingippool.infrastructure.cluster.x-k8s.io/) \"hux-lab1\" is invalid: spec.floatingIPNetwork: Invalid value: 0: spec.floatingIPNetwork in body should have at least 1 properties"}

This behaviour seems to have been changed in: https://github.com/kubernetes-sigs/cluster-api-provider-openstack/pull/1972

What did you expect to happen: floatingIPNetwork to be optional or for us to change it to required

Anything else you would like to add: [Miscellaneous information that will assist in solving the issue.]

Environment: