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