0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

no_proxyに連続した複数IPアドレスを指定する方法

Last updated at Posted at 2022-04-19

no_proxyにはサブネットを指定できないため、IPアドレスを一つずつ指定する必要がある。
連続した複数のIPアドレスを指定する場合、以下のようにすればIPアドレスを一つずつ指定せずに済む。

  • 172.16.10.5 ~ 172.16.10.24のIPアドレスをno_proxyに指定する場合

/etc/profile.d/proxy.shに以下を指定

export http_proxy=<proxyのURL>
export https_proxy=${http_proxy}
export HTTP_PROXY=${http_proxy}
export HTTPS_PROXY=${http_proxy}

export no_proxy=localhost,127.0.0.1
export no_proxy=${no_proxy},.example.com,.localdomain
for i in $(seq 5 24); do export no_proxy=${no_proxy},172.16.10.${i}; done

export NO_PROXY=${no_proxy}
0
0
1

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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?