解决go依赖包安装问题

设置go代理

echo "export GOPROXY=https://goproxy.cn" >> ~/.profile && source ~/.profile

下载github的package替代golang.org的package

git clone --depth=1 https://github.com/golang/text.git $GOPATH/src/golang.org/x

git clone --depth=1 https://github.com/golang/crypto.git $GOPATH/src/golang.org/x/crypto

git clone --depth=1  https://github.com/golang/net.git $GOPATH/src/golang.org/x/net

git clone --depth=1  https://github.com/golang/sys.git $GOPATH/src/golang.org/x/sys

git clone --depth=1  https://github.com/golang/tools.git $GOPATH/src/golang.org/x/tools

go get -u github.com/qiniu/x/log

原文地址:https://www.cnblogs.com/beilong/p/12128222.html