Question

How configure docker with ipv6?

Posted December 23, 2019 823 views
DockerIPv6

Hi,

I was following the steps of the official docker documentation (https://docs.docker.com/config/daemon/ipv6/) about to enable ipv6 in docker and the containers have ip6 but when I execute ping6 google.com, all packages are lost. The container does not have a connection using ip6 with the external hosts.

I’ve configured the next in the daemon.json:

{
"ipv6": true,
"fixed-cidr-v6": "xxxx:xxxx:xxxx/124"
}

I use /124 because DigitalOcean only give 14 ipv6 addresses.
Also, I execute the following commands too:

net.ipv6.conf.default.forwarding = 1
net.ipv6.conf.all.forwarding=1

The container has a ip6:

18: eth0@if19: <BROADCAST,MULTICAST,UP,LOWER_UP,M-DOWN> mtu 1500 state UP
    inet6 2604:a880:2:d0::a02:f002/124 scope global flags 02
       valid_lft forever preferred_lft forever
    inet6 fe80::42:acff:fe11:2/64 scope link
       valid_lft forever preferred_lft forever

And when I execute:

ping6 google.com

The result is:

--- google.com ping statistics ---
9 packets transmitted, 0 packets received, 100% packet loss

Can somebody help me?

edited by MattIPv4

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
1 answer

The fixed-cidr-v6 subnet should be minimum /80

Submit an Answer