greenpau / cni-plugins

CNI Plugins compatible with nftables
Apache License 2.0
48 stars 13 forks source link

Cannot find package #13

Closed bhundven closed 3 years ago

bhundven commented 3 years ago

While trying to go get the portmap and firewall plugins, I get the following:

$ go get -u github.com/greenpau/cni-plugins/cmd/cni-nftables-portmap
cannot find package "github.com/containernetworking/cni/pkg/types/current" in any of:
    /usr/lib/go-1.15/src/github.com/containernetworking/cni/pkg/types/current (from $GOROOT)
    /home/bhundven/go/src/github.com/containernetworking/cni/pkg/types/current (from $GOPATH)

That path doesn't seem to exist anymore. I think this needs to change to 1.0.0: github.com/containernetworking/cni/pkg/types/100

bhundven commented 3 years ago

Rather, change the import from:

"github.com/containernetworking/cni/pkg/types/current"

to

current "github.com/containernetworking/cni/pkg/types/100"
bhundven commented 3 years ago

Updating the go.mod with go get -u github.com/containernetworking/cni@0050bfa allowed me to run make and pass. I think there may be more work to use newer cni.

greenpau commented 3 years ago

@bhundven , it should be good now.