当前位置:网站首页>Golang sets the small details of goproxy proxy proxy, which is applicable to go module download timeout and Alibaba cloud image go module download timeout
Golang sets the small details of goproxy proxy proxy, which is applicable to go module download timeout and Alibaba cloud image go module download timeout
2022-07-04 12:54:00 【Late night watch listening】
problem
A few days ago, I was curious to add an official community group of domestic alliance chain blockchain , Then someone compiles a tool go module Download has timed out , Then I used Alibaba cloud's image , The command looks ok as follows , But still timeout .

verification
But I clean up here module cache , Verify that the Alibaba cloud image is indeed hung , But it is normal to change other mirror agents , That's ridiculous .
Analyze the causes and solutions
Then the reason must be the configuration problem , So I checked the man's bash command , There is a problem , as follows :
Be reasonable export The command is always valid when the terminal is not turned off , But he has another detail here. I don't know if you have found it , He abused it sudo command , He compiled the command with sudo make, however root What the user is looking for golang Environment variables have not been modified , So the last one export The command is input in vain .
It's also easy to solve , Directly use the following command to modify go env environment variable
go env -w GO111MODULE=on #-w Indicates to modify the default value of the environment variable
go env -w GOPROXY=https://goproxy.io,direct
Use... After modification go env Check whether the order has been changed , Last make Get it done .

I have to say that it's really cool to pretend to be forced :)
🥰 If you like, you can also buy me juice 🥰
Reward / Donate

边栏推荐
- eclipse链接数据库中测试SQL语句删除出现SQL语句语法错误
- AI 绘画极简教程
- DC-5靶机
- CA:用于移动端的高效坐标注意力机制 | CVPR 2021
- R language -- readr package reads and writes data
- Dry goods sorting! How about the development trend of ERP in the manufacturing industry? It's enough to read this article
- Transformer principle and code elaboration (tensorflow)
- 轻松玩转三子棋
- 美团·阿里关于多模态召回的应用实践
- Global and Chinese markets for soluble suture 2022-2028: Research Report on technology, participants, trends, market size and share
猜你喜欢

C#/VB.NET 给PDF文档添加文本/图像水印

Introduction to the button control elevatedbutton of the fleet tutorial (the tutorial includes the source code)

《预训练周刊》第52期:屏蔽视觉预训练、目标导向对话

洞见科技解决方案总监薛婧:联邦学习助力数据要素安全流通

runc hang 导致 Kubernetes 节点 NotReady

Alibaba cloud award winning experience: build a highly available system with polardb-x

CA:用于移动端的高效坐标注意力机制 | CVPR 2021

分布式事务相关概念与理论

美团·阿里关于多模态召回的应用实践

DC-5靶机
随机推荐
面向个性化需求的在线云数据库混合调优系统 | SIGMOD 2022入选论文解读
I want to talk about yesterday
Entity framework calls Max on null on records - Entity Framework calling Max on null on records
Alibaba cloud award winning experience: build a highly available system with polardb-x
洞见科技解决方案总监薛婧:联邦学习助力数据要素安全流通
Can Console. Clear be used to only clear a line instead of whole console?
Detailed explanation of mt4api documentary and foreign exchange API documentary interfaces
2022年中国移动阅读市场年度综合分析
Dry goods sorting! How about the development trend of ERP in the manufacturing industry? It's enough to read this article
Implementation mode and technical principle of MT4 cross platform merchandising system (API merchandising, EA merchandising, nj4x Merchandising)
Play Sanzi chess easily
诸神黄昏时代的对比学习
ArcGis利用栅格处理工具进行影像裁剪
C fonctions linguistiques
jsonp
数据库锁表?别慌,本文教你如何解决
实时云交互如何助力教育行业发展
Vit (vision transformer) principle and code elaboration
Reinforcement learning - learning notes 1 | basic concepts
WPF双滑块控件以及强制捕获鼠标事件焦点