由 BG6RSH » 周三 5月 29, 2024 9:20 am
三、debian全局代理(nano /etc/profile.d/proxy.sh)
#!/bin/sh
# 设置 HTTP 代理
export HTTP_PROXY="http://username:password@your-proxy-server:port"
export http_proxy="http://username:password@your-proxy-server:port"
# 设置 HTTPS 代理
export HTTPS_PROXY="http://username:password@your-proxy-server:port"
export https_proxy="http://username:password@your-proxy-server:port"
# 设置 FTP 代理
export FTP_PROXY="http://username:password@your-proxy-server:port"
export ftp_proxy="http://username:password@your-proxy-server:port"
# 设置不需要代理的地址
export NO_PROXY="localhost,127.0.0.1,10.0.0.0/8,.yourdomain.com"
export no_proxy="localhost,127.0.0.1,localaddress,.yourdomain.com"
三、debian全局代理(nano /etc/profile.d/proxy.sh)
[Codebox=bash file=proxy.sh]#!/bin/sh
# 设置 HTTP 代理
export HTTP_PROXY="http://username:password@your-proxy-server:port"
export http_proxy="http://username:password@your-proxy-server:port"
# 设置 HTTPS 代理
export HTTPS_PROXY="http://username:password@your-proxy-server:port"
export https_proxy="http://username:password@your-proxy-server:port"
# 设置 FTP 代理
export FTP_PROXY="http://username:password@your-proxy-server:port"
export ftp_proxy="http://username:password@your-proxy-server:port"
# 设置不需要代理的地址
export NO_PROXY="localhost,127.0.0.1,10.0.0.0/8,.yourdomain.com"
export no_proxy="localhost,127.0.0.1,localaddress,.yourdomain.com"[/Codebox]