diff --git a/cmd/cnivpc/main.go b/cmd/cnivpc/main.go index 31ec8c1..3439f3d 100644 --- a/cmd/cnivpc/main.go +++ b/cmd/cnivpc/main.go @@ -175,6 +175,7 @@ func cmdAdd(args *skel.CmdArgs) error { err = addPodNetworkRecord(podName, podNS, sandBoxId, pNet) if err != nil { ulog.Warnf("Record pod network info for %s/%s, sandbox: %s, error: %v", podName, podNS, sandBoxId, err) + return fmt.Errorf("failed to record pod network: %v", err) } // Fill result routes ulog.Infof("[Result]: %+v", result)