Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove a log for v1 migration error #266

Merged
merged 1 commit into from
Feb 2, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 0 additions & 13 deletions v2/runners/coild_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ import (
"net"
"strings"

"github.com/containernetworking/plugins/pkg/ip"
"github.com/containernetworking/plugins/pkg/ns"
coilv2 "github.com/cybozu-go/coil/v2/api/v2"
"github.com/cybozu-go/coil/v2/pkg/cnirpc"
"github.com/cybozu-go/coil/v2/pkg/constants"
Expand Down Expand Up @@ -254,17 +252,6 @@ func (s *coildServer) Del(ctx context.Context, args *cnirpc.CNIArgs) (*emptypb.E
return nil, newInternalError(err, "failed to destroy pod network")
}

// This is for migration from Coil v1.
// TODO: eventually this block should be removed.
if args.Netns != "" {
err := ns.WithNetNSPath(args.Netns, func(_ ns.NetNS) error {
return ip.DelLinkByName(args.Ifname)
})
if err != nil {
logger.Sugar().Errorw("intentionally ignoring error for v1 migration", "error", err)
}
}

if err := s.nodeIPAM.Free(ctx, args.ContainerId, args.Ifname); err != nil {
logger.Sugar().Errorw("failed to free addresses", "error", err)
return nil, newInternalError(err, "failed to free addresses")
Expand Down
Loading