Skip to content

Commit 708ee98

Browse files
Merge pull request #229 from linode/shared-ip-check-fix
[fix] don't assume the IP holder immediately reflects the new IP to share for a cilium-bgp-lb Service
2 parents a13fc1c + 7137f14 commit 708ee98

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

cloud/linode/cilium_loadbalancers.go

+1-2
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,6 @@ func (l *loadbalancers) createSharedIP(ctx context.Context, nodes []*v1.Node) (s
221221
if err != nil {
222222
return "", err
223223
}
224-
inClusterAddrs = append(inClusterAddrs, newSharedIP.Address)
225224
// if any of the addrs don't exist on the ip-holder (e.g. someone manually deleted it outside the CCM),
226225
// we need to exclude that from the list
227226
// TODO: also clean up the CiliumLoadBalancerIPPool for that missing IP if that happens
@@ -230,7 +229,7 @@ func (l *loadbalancers) createSharedIP(ctx context.Context, nodes []*v1.Node) (s
230229
klog.Infof("error getting shared IPs in cluster: %s", err.Error())
231230
return "", err
232231
}
233-
addrs := []string{}
232+
addrs := []string{newSharedIP.Address}
234233
for _, i := range inClusterAddrs {
235234
if slices.Contains(ipHolderAddrs, i) {
236235
addrs = append(addrs, i)

0 commit comments

Comments
 (0)