Improve the documentation examples and advice for native IPv6 Docker networking #19556
Description
Is this a docs issue?
- My issue is about the documentation content or website
Type of issue
Other
Description
Few issues:
- The bare minimum “example” should generally be a /64 (whereby we route a /64 or larger to the Docker host) instead of /112 or potentially some other outside nibble-bit boundary prefix length.
- The IPv6 notation used in the documentation is not correct, in direct violation of RFC5952
- ULAs shouldn't be promoted or advised, sources below:
- https://datatracker.ietf.org/doc/draft-ietf-v6ops-ula/
- https://datatracker.ietf.org/doc/html/draft-ietf-6man-rfc6724-update-06
- An additional problem with ULA is enforcing the need for NAT66 which in turn breaks native IPv6 networking and the benefits of end-to-end principle, the usage of NAT66 also introduces the need for ALG (in Linux world, called NAT Helpers) which renders the benefits of IPv6 to zero, on par with traditional NAT44 or NAT444 environments.
- Overall lacks network engineering point of view and operational insights
Location
https://docs.docker.com/config/daemon/ipv6/
Suggestion
For point 1:
We simply replace the “2001:0DB8::/112” string with “2001:db8::/64”
The idea for a minimum /64 came from the fact that IPv6 networking was to be based on prefix-length, and not “number of addresses” as the address space is 128-Bits. This was reflected in the original SLAAC specifications, in addition to additional operational information on BCOP-690. We should not be promoting archaic IPv4-centric mentality in native IPv6 networking.
For point 2:
Firstly, the alphabets in an IPv6 address is lower-case always, secondly we always remove all leading zeros in the compressed IPv6 notation format, meaning in effect:
- “2001:0DB8::/64” is not recommended
- “2001:db8::/64” is recommended
Please refer to section 4 of RFC5952
For point 3, 4 & 5:
I am willing to help improve this aspect of the Docker IPv6 documentation by integrating network engineering perspective and operational insights directly into the Docker docs.
The basic idea of native IPv6 networking is: No NAT66/NPTv6 or ULA.
I'm of course aware of poorly implemented IPv6 in popular cloud providers/IaaS companies, whereby the user is forced to rely on ULA/NAT66 or some hacks with NDP Proxy or MACVLAN, but of course, this is not a valid reason to push for ULA/NAT66/NPTv6 from the official documentation of Docker.
I authored an extensive native IPv6 best practices guide below, that folks may want to give a read on to get fully thorough information that simply cannot be reproduced in a tiny GitHub issue:
https://blog.apnic.net/2023/04/04/ipv6-architecture-and-subnetting-guide-for-network-engineers-and-operators/
I've written extensively on various topics of network engineering, in particular IPv6. I'm personally willing to help improve the Docker docs to push for native IPv6 networking using some realistic examples. I'm not sure how the Docker docs writing/improvement process is handled, but if I could get in a direct discussion with the relevant folks, it would be much appreciated.
On a side note, I'm happily using Docker for a few years now, with native IPv6 networking (no ULA/NAT66/NPTv6) 🙂