go打包报错 Go Bulid 报错 A connection attempt failed

女爷i 2023-01-05 12:51 219阅读 0赞

go build 打包时报错:

A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

原因: go.mod 代理连接出错

解决:go.mod 设置代理

  1. golang1.13.x 可以直接执行:
  2. go env -w GO111MODULE=on
  3. go env -w GOPROXY=https://goproxy.cn,direct

发表评论

表情:
评论列表 (有 0 条评论,219人围观)

还没有评论,来说两句吧...

相关阅读