Skip to content

Commit

Permalink
use different ip crd with provider suffix for pod multus nic
Browse files Browse the repository at this point in the history
  • Loading branch information
hongzhen-ma committed Dec 28, 2021
1 parent cdf85a5 commit 6f35670
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions pkg/controller/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -334,15 +334,6 @@ func (c *Controller) InitIPAM() error {
if _, _, _, err = c.ipam.GetStaticAddress(ipamKey, ip.Name, ip.Spec.IPAddress, ip.Spec.MacAddress, ip.Spec.Subnet, false); err != nil {
klog.Errorf("failed to init IPAM from IP CR %s: %v", ip.Name, err)
}
for i := range ip.Spec.AttachSubnets {
if i == len(ip.Spec.AttachIPs) || i == len(ip.Spec.AttachMacs) {
klog.Errorf("attachment IP/MAC of IP CR %s is invalid", ip.Name)
break
}
if _, _, _, err = c.ipam.GetStaticAddress(ipamKey, ip.Name, ip.Spec.AttachIPs[i], ip.Spec.AttachMacs[i], ip.Spec.AttachSubnets[i], false); err != nil {
klog.Errorf("failed to init IPAM from IP CR %s: %v", ip.Name, err)
}
}
}

nodes, err := c.nodesLister.List(labels.Everything())
Expand Down

0 comments on commit 6f35670

Please sign in to comment.