LoginSignup
2
2

More than 3 years have passed since last update.

Centos7環境のProxy設定まとめ

Posted at

centos7でプロキシ(認証あり)を利用する場合のメモです。

profile

vi /etc/profile

最終行に追加
#プロキシ設定
PROXY="http://<user>:<pass>@<proxy_host>:<proxy_port>" # proxyサーバのドメインとポートを指定
export http_proxy=$PROXY
export HTTP_PROXY=$PROXY
export https_proxy=$PROXY
export HTTPS_PROXY=$PROXY

yum

vi /etc/yum.conf

最終行に追加
#プロキシ設定
proxy=http://<user>:<pass>@<proxy_host>:<proxy_port>

rpm

rpm --httpproxy <user>:<pass>@<proxy_host> --httpport <proxy_port>

docker

vi /etc/default/docker
export http_proxy=http://<user>:<pass>@<proxy_host>:<proxy_port>

参考サイト

https://qiita.com/KuwaK/items/a33c625d1472b0ab2e16
https://qiita.com/Ki4mTaria/items/d10f3d562d02a0a4ded4

2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2