feat(network): add support for static IPv6 assignment
This PR introduces end-to-end support for assigning static IPv6 addresses to containers, both via the command line and through nerdctl compose.
Key changes:
-
A new
--ip6flag is added tonerdctl runto allow direct assignment of a static IPv6 address. -
The CNI bridge configuration for IPv6 networks is now updated to declare the
"ips"capability. This is required by libcni to process static IP capability arguments. -
To prevent regressions in downstream CNI plugins (like dnsname and firewall), the
"dns"and"portMappings"capabilities are also explicitly declared for IPv6 networks. This avoids issues where implicit capabilities were being dropped. -
The compose parser now recognizes the
ipv6_addressfield within a service's network configuration and translates it to the--ip6flag during container creation. -
Adds comprehensive integration tests for static IPv4, IPv6, and dual-stack IP assignment, as well as unit tests for compose file parsing, to validate the new functionality and prevent regressions.
fixes #4597