LoginSignup
6
6

More than 5 years have passed since last update.

DockerでIPv6を有効にする

Posted at

概要

Dockerでは、defaultでIPv6が無効になっています。
以下の設定で、有効にします。

CentOS7の場合

/etc/docker/daemon.jsonをなければ作成して、以下を記述します。

/etc/docker/daemon.json
{
  "ipv6": true,
  "fixed-cidr-v6": "2001:db8:1::/64"
}

dockerをreloadします。

$ sudo systemctl reload docker

macの場合

Docker for Macの「Preferences(設定)」 -> 「daemonタブ」 -> その中の「Advanced」タブで、
以下のようにCentOS7のものと同じものを追記して、「Apply & Restart」をクリックします。
Screen Shot 2018-09-08 at 16.19.24.png

参考

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