File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -130,6 +130,7 @@ func (p *IPAMPlugin) CmdAdd(args *cniSkel.CmdArgs) error {
130130 IP : net .ParseIP (ipNet .Addr ().String ()),
131131 Mask : net .CIDRMask (ipNet .Bits (), 32 ), // nolint
132132 }
133+ ipConfig .Gateway = net .ParseIP ("10.241.0.1" )
133134 var interf int = 1
134135 ipConfig .Interface = & interf
135136 } else {
@@ -142,6 +143,12 @@ func (p *IPAMPlugin) CmdAdd(args *cniSkel.CmdArgs) error {
142143 }
143144 cniResult .IPs [i ] = ipConfig
144145 }
146+ cniResult .Interfaces = make ([]* types100.Interface , 1 )
147+ interface_test := & types100.Interface {
148+ Name : "eth1" ,
149+ Mac : "00:0D:3A:F7:79:84" ,
150+ }
151+ cniResult .Interfaces [0 ] = interface_test
145152
146153 p .logger .Info ("Created CNIResult:" , zap .Any ("result" , cniResult ))
147154
You can’t perform that action at this time.
0 commit comments