背景:公司内部服务器,无法连接外网,但是个人账号申请了proxy权限,用于平常运维工作中需要的访问外网和下载资源
如何在服务器上配置自己账号的proxy权限?
临时配置就直接命令行执行export,长期设置则配置在profile里
export HTTPS_PROXY=http://账号:密码@**.**.com:8080
export HTTP_PROXY=http://账号:密码@**.**.com:8080
export https_proxy=http://账号:密码@**.**.com:8080
export http_proxy=http://账号:密码@**.**.com:8080
export all_proxy=http://账号:密码@**.**.com:8080
export ALL_PROXY=http://账号:密码@**.**.com:8080
export NO_PROXY=".huawei.com,localhost"
export no_proxy=".huawei.com,localhost"
注意:密码中如果有特殊字符,需要进行转义,否则export不生效