当我试图安装Burrow https://github.com/linkedin/Burrow#build-and-install时
go get github.com/linkedin/Burrow
我得到了以下错误:
package gopkg.in/gcfg.v1: unrecognized import path "gopkg.in/gcfg.v1"
(https fetch: Get https://gopkg.in/gcfg.v1?go-get=1: proxyconnect tcp: dial tcp :0: getsockopt: connection refused)
我已经通过以下方式建立了代理:
export http_proxy=myproxy:port
export https_proxy=myproxy:port
编辑:
go get -u gopkg.in/gcfg.v1
也给出了同样的错误:
package gopkg.in/gcfg.v1: unrecognized import path "gopkg.in/gcfg.v1"
(https fetch: Get https://gopkg.in/gcfg.v1?go-get=1: proxyconnect tcp: dial tcp :0: getsockopt: connection refused)
Edit1
go get -v gopkg.in/gcfg.v1
Fetching https://gopkg.in/gcfg.v1?go-get=1
https fetch failed: Get https://gopkg.in/gcfg.v1?go-get=1: proxyconnect tcp: dial tcp :0: getsockopt: connection refused
package gopkg.in/gcfg.v1: unrecognized import path "gopkg.in/gcfg.v1" (https fetch: Get https://gopkg.in/gcfg.v1?go-get=1: proxyconnect tcp: dial tcp :0: getsockopt: connection refused)
发布于 2020-04-15 06:00:55
我也犯了同样的错误。原来我的https代理是不正确的。确保http和https代理都指向以http开头的同一个代理。
export http_proxy=<http://proxy:port>
export https_proxy=<http://proxy:port>
发布于 2021-05-19 06:45:00
从您的PC中删除env HTTPS_PROXY:
发布于 2018-03-07 14:56:28
我用以下方法解决了这个问题:
export https_proxy=$http_proxy
为了更持久的解决方案,可以更新/etc/环境。
https://stackoverflow.com/questions/42295200
复制相似问题