mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-29 14:37:00 +00:00
Fix legacy floatingip
If user specify floating-network-id by annotation rather than cloud provider file, openstack cloud provider don't delete floatingip when deleting LoadBalancer service.
This commit is contained in:
parent
e633a1604f
commit
e5b7f0e7ba
@ -1116,7 +1116,7 @@ func (lbaas *LbaasV2) EnsureLoadBalancerDeleted(clusterName string, service *v1.
|
||||
return nil
|
||||
}
|
||||
|
||||
if lbaas.opts.FloatingNetworkId != "" && loadbalancer != nil {
|
||||
if loadbalancer != nil && loadbalancer.VipPortID != "" {
|
||||
portID := loadbalancer.VipPortID
|
||||
floatingIP, err := getFloatingIPByPortID(lbaas.network, portID)
|
||||
if err != nil && err != ErrNotFound {
|
||||
|
Loading…
Reference in New Issue
Block a user