LoginSignup
5
4

More than 1 year has passed since last update.

dnfでプロキシを設定する

Last updated at Posted at 2020-11-18

CentOS 8になって、パッケージマネージャーがyumからdnfになってプロキシ設定はどうするんだろう?とちょっと困ったので。

dnfの場合、dnf.confmainセクションに記述します。

/etc/dnf/dnf.conf

[main]
...
proxy=http://[your-proxy-host]:[your-proxy-port]

なお、yumの時はyum.confでした。

/etc/yum.conf

[main]
...
proxy=http://[your-proxy-host]:[your-proxy-port]

dnfになって、パスの階層が変わっていたので、ということでメモでした。

ちなみに、/etc/dnf.confというファイルはあったりします。

最初、ここに書くのかと思いました…。

aptの場合は?

aptの場合は、こちらへ。

5
4
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
5
4