aboutsummaryrefslogtreecommitdiffstats
path: root/internal
diff options
context:
space:
mode:
authorKuralamudhan Ramakrishnan <kuralamudhan.ramakrishnan@intel.com>2020-10-06 13:19:40 -0700
committerKuralamudhan Ramakrishnan <kuralamudhan.ramakrishnan@intel.com>2020-10-06 18:42:18 -0700
commit9fbc8db799177e67c6100152ba706c8e934bb73e (patch)
tree99125739c59762f864a6fb452898d54301719dda /internal
parente079d27a3ffd9a324ed61ceb1d9200c8a4ccfa7f (diff)
fixing interface names for the cni-proxy related cni plugins
Signed-off-by: Kuralamudhan Ramakrishnan <kuralamudhan.ramakrishnan@intel.com> Change-Id: I136c26213840881087ac18bac0778046807632ac
Diffstat (limited to 'internal')
-rw-r--r--internal/pkg/cniserver/cni.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/internal/pkg/cniserver/cni.go b/internal/pkg/cniserver/cni.go
index ee848f7..7bfd0a1 100644
--- a/internal/pkg/cniserver/cni.go
+++ b/internal/pkg/cniserver/cni.go
@@ -140,7 +140,11 @@ func (cr *CNIServerRequest) addMultipleInterfaces(ovnAnnotation, namespace, podN
defaultGateway = "true"
}
- klog.Infof("addMultipleInterfaces: ipAddress %v %v", ipAddress, interfaceName)
+ if interfaceName == "*" && cr.IfName != "eth0" {
+ defaultGateway = "false"
+ }
+
+ klog.Infof("addMultipleInterfaces: ipAddress-%v ovn4nfv-interface-%v cni-ifname-%v", ipAddress, interfaceName, cr.IfName)
interfacesArray, err = app.ConfigureInterface(cr.Netns, cr.SandboxID, cr.IfName, namespace, podName, macAddress, ipAddress, gatewayIP, interfaceName, defaultGateway, index, config.Default.MTU, isDefaultGW)
if err != nil {
klog.Errorf("Failed to configure interface in pod: %v", err)