linux中的常用的proxy 代理方式


  1. 设置ALL_PROXY环境变量
    export ALL_PROXY=socks5://127.0.0.1:1080
    支持socks5 http https
    取消
    export ALL_PROXY=""

2.使用proxychains

github开源地址:https://github.com/rofl0r/proxychains-ng

  1. vpxN方式全局代理

...

4 GO下载模块代理

# Enable the go modules feature
export GO111MODULE=on
# Set the GOPROXY environment variable
export GOPROXY=https://goproxy.io

5 Git下的代理

#全局的
git config --global http.proxy 'socks5://127.0.0.1:1080'
git config --global https.proxy 'socks5://127.0.0.1:1080'

#只对github.com
git config --global http.https://github.com.proxy socks5://127.0.0.1:1080

#取消代理
git config --global --unset http.https://github.com.proxy


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM