当前位置:网站首页>GO GOPROXY代理设置
GO GOPROXY代理设置
2022-07-31 00:16:00 【web15286201346】
一 背景:
当你执行go get命令的时候显示超时proxy.golang.org --> timeout
leyangjundeMacBook-Pro:photoleyangjun$ go get -u github.com/spf13/cobra
go get -u github.com/spf13/cobra
go get github.com/spf13/cobra: module github.com/spf13/cobra: Get https://proxy.golang.org/github.com/spf13/cobra/@v/list: dial tcp 142.251.10.141:443: i/o timeout
二:原因
https://proxy.golang.org/github.com/ 国内无法访问
三:换成国内可访问的地址,设置GOPROXY代理
go env -w GOPROXY=https://goproxy.cn,direct
go env -w GOSUMDB=off (关闭包的有效性验证)
go env -w GOSUMDB=“sum.golang.google.cn” (也可设置国内提供的sum 验证服务)
备注:-w 标记 要求一个或多个形式为 NAME=VALUE 的参数且覆盖默认的设置
先自我介绍一下,小编13年上师交大毕业,曾经在小公司待过,去过华为OPPO等大厂,18年进入阿里,直到现在。深知大多数初中级java工程师,想要升技能,往往是需要自己摸索成长或是报班学习,但对于培训机构动则近万元的学费,着实压力不小。自己不成体系的自学效率很低又漫长,而且容易碰到天花板技术停止不前。因此我收集了一份《java开发全套学习资料》送给大家,初衷也很简单,就是希望帮助到想自学又不知道该从何学起的朋友,同时减轻大家的负担。添加下方名片,即可获取全套学习资料哦
边栏推荐
猜你喜欢

How to solve types joiplay simulator does not support this game

Asser uses ant sword to log in

IOT cross-platform component design scheme

在微服务中使用事件溯源的六大原因 - Herath

Shell脚本 if语句

MySQL面试题

如何在WordPress网站上添加导航菜单

Gabor滤波器学习笔记

How to solve the error of joiplay simulator

.NET Cross-Platform Application Development Hands-on Tutorial | Build a Kanban-style Todo App with Uno Platform
随机推荐
常用的正则表达式
DATA AI Summit 2022提及到的对 aggregate 的优化
xss的绕过
An easy-to-use interface testing tools - the Postman
【深入浅出玩转FPGA学习14----------测试用例设计2】
[In-depth and easy-to-follow FPGA learning 14----------Test case design 2]
joiplay模拟器如何导入游戏存档
leetcode 406. Queue Reconstruction by Height
SWM32系列教程6-Systick和PWM
MySQL数据库(基础)
MySQL数据库的truncate与delete区别
二叉查找树的定义,查找,插入,删除
(五)fastai应用
MySQL grant statements
Installation considerations for pytorch
MySQL数据库面试题总结(2022最新版)
pytorch bilinear interpolation
MySQL的grant语句
The difference between substring and substr in MySQL
Error ER_NOT_SUPPORTED_AUTH_MODE Client does not support authentication protocol requested by serv