Hi.
We're using v0.6.3 of this package, and we run into the following problem when cross-compiling under Linux:
build my-binary: cannot find module for path github.com/docker/docker-credential-helpers/registryurl
The build commands we are using is
env GOOS=darwin GOARCH=amd64 go mod download
env GOOS=darwin GOARCH=amd64 go build -v -x -o my-binary
I'm experiencing this problem with Go 1.12 on Ubuntu 18.04 as well as on Travis-CI using the following setup:
sudo: true
os: linux
language: go
go:
- 1.12.x
env:
global:
- GO111MODULE=on
- GOPROXY=https://proxy.golang.org
Building for Linux and Windows works fine. Building the library on osx works fine too. We do not import github.com/docker/docker-credential-helpers/registryurl at all.
My handler_darwin.go looks as follows:
package credentialmanager
import (
"net/url"
"github.com/docker/docker-credential-helpers/osxkeychain"
)
// SetCreds stores the credentials consisting of an endpoint and an api token in the keychain.
func SetCreds(endPoint url.URL, apiToken string) error {
return setCreds(osxkeychain.Osxkeychain{}, endPoint, apiToken)
}
// GetCreds reads the credentials and returns an endpoint, the api token, or potentially an error.
func GetCreds() (url.URL, string, error) {
return getCreds(osxkeychain.Osxkeychain{})
}
// SetInstallCreds sets the install credentials
func SetInstallCreds(creds string) error {
return setInstallCreds(osxkeychain.Osxkeychain{}, creds)
}
// GetInstallCreds gets the install credentials
func GetInstallCreds() (string, error) {
return getInstallCreds(osxkeychain.Osxkeychain{})
}
Hi.
We're using v0.6.3 of this package, and we run into the following problem when cross-compiling under Linux:
The build commands we are using is
I'm experiencing this problem with Go 1.12 on Ubuntu 18.04 as well as on Travis-CI using the following setup:
Building for Linux and Windows works fine. Building the library on osx works fine too. We do not import
github.com/docker/docker-credential-helpers/registryurlat all.My
handler_darwin.golooks as follows: