Before you can use IPv6 in Docker containers or swarm services, you need to enable IPv6 support in the Docker daemon. Afterward, you can choose to use either IPv4 or IPv6 (or both) with any container, service, or network.
Note: IPv6 networking is only supported on Docker daemons running on Linux hosts.
Edit /etc/docker/daemon.json, set the ipv6 key to true and the fixed-cidr-v6 key to your IPv6 subnet. In this example we are setting it to 2001:67c:1254:64:f8de:1111::1/96
.
"fixed-cidr-v6"
should be a subnet of your IPv6 address (the one you use to ssh at the beginning). For example, if the IPv6 address is 2001:67c:1254:64:f8de::1, you are supposed to set it as 2001:67c:1254:64:f8de:xxxx::1/96