Skip to content

Commit

Permalink
fix(cnivpc): return error when add pod network record failed (#41)
Browse files Browse the repository at this point in the history
  • Loading branch information
fioncat authored Aug 2, 2024
1 parent c9fa778 commit 5d20363
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/cnivpc/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,8 @@ func cmdAdd(args *skel.CmdArgs) error {

err = addPodNetworkRecord(podName, podNS, sandBoxId, netNS, pNet)
if err != nil {
log.Warningf("Failed to record pod network info for %s/%s, sandbox: %s", podName, podNS, sandBoxId)
log.Errorf("Record pod network info for %s/%s, sandbox: %s, ip: %s, error: %v", podName, podNS, sandBoxId, pNet.VPCIP, err)
return fmt.Errorf("failed to add pod network record: %v", err)
}
// Fill result routes
log.Infof("[Result]: %+v", result)
Expand Down

0 comments on commit 5d20363

Please sign in to comment.