danhale-git / craft

Deploy and manage mc bedrock servers
Apache License 2.0
0 stars 0 forks source link

Docker vendor errors on ubuntu install #13

Open danhale-git opened 3 years ago

danhale-git commented 3 years ago
$ go install .
# github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs
../../docker/docker/vendor/github.com/containerd/containerd/errdefs/errors.go:54:9: undefined: "github.com/docker/docker/vendor/github.com/pkg/errors".Is
../../docker/docker/vendor/github.com/containerd/containerd/errdefs/errors.go:59:9: undefined: "github.com/docker/docker/vendor/github.com/pkg/errors".Is
../../docker/docker/vendor/github.com/containerd/containerd/errdefs/errors.go:65:9: undefined: "github.com/docker/docker/vendor/github.com/pkg/errors".Is
...
danhale-git commented 3 years ago

https://github.com/moby/moby/issues/28269

https://github.com/containerd/containerd/issues/4703

danhale-git commented 3 years ago

The errors were due to incorrect go version, downloaded the latest and updated the setup issue.

New errors:

$ go get github.com/danhale-git/craft
# github.com/danhale-git/craft/internal/craft
go/src/github.com/danhale-git/craft/internal/craft/dockerclient.go:103:4: cannot use "github.com/docker/go-connections/nat".PortSet literal (type "github.com/docker/go-connections/nat".PortSet) as type "github.com/docker/docker/vendor/github.com/docker/go-connections/nat".PortSet in field value
go/src/github.com/danhale-git/craft/internal/craft/dockerclient.go:113:4: cannot use portBinding (type "github.com/docker/go-connections/nat".PortMap) as type "github.com/docker/docker/vendor/github.com/docker/go-connections/nat".PortMap in field value
danhale-git commented 3 years ago

To successfully install, go through each error deleting the vendor directory in the package like so: rm -rf github.com/docker/docker/vendor/ (re: the above example)

codeWithUtkarsh commented 3 years ago

@danhale-git Can you please help me with the below error? github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs go/src/github.com/docker/docker/vendor/github.com/containerd/containerd/errdefs/errors.go:54:9: undefined: "github.com/docker/docker/vendor/github.com/pkg/errors".Is

danhale-git commented 3 years ago

Hi @codeWithUtkarsh. I just added goreleaser so you should be able to download a binary for windows or linux here.

If you want to build locally, this comment has the gist of what fixed similar errors for me.

Further reading in the links in this comment.