Skip to content

Commit d185191

Browse files
author
Matt Pryor
committed
Attempting to create a FIP without a network ID will fail anyway and this makes the tests pass
1 parent 98f95b2 commit d185191

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

pkg/cloud/services/networking/floatingip.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ limitations under the License.
1717
package networking
1818

1919
import (
20-
"errors"
2120
"time"
2221

2322
"github.com/gophercloud/gophercloud/openstack/networking/v2/extensions/attributestags"
@@ -47,11 +46,6 @@ func (s *Service) GetOrCreateFloatingIP(openStackCluster *infrav1.OpenStackClust
4746
fpCreateOpts.FloatingIP = ip
4847
}
4948

50-
// Trying to create a new floating IP is not possible without an external network
51-
if openStackCluster.Status.ExternalNetwork == nil || openStackCluster.Status.ExternalNetwork.ID == "" {
52-
return nil, errors.New("cannot create floating IP without external network")
53-
}
54-
5549
fpCreateOpts.FloatingNetworkID = openStackCluster.Status.ExternalNetwork.ID
5650
fpCreateOpts.Description = names.GetDescription(clusterName)
5751

0 commit comments

Comments
 (0)