[Documentation] missing information on how to enable ipv6 for build network
Problem to solve
I want to use gitlab-runner with the docker executor.
The environment shall support ipv6 and the containers from the job should be accessible via ipv6.
I followed the docs at https://docs.gitlab.com/runner/executors/docker.html#create-a-network-for-each-job and related info
on how to enable ipv6 for docker.
And while ipv6 for docker working I could still not bring up the gitlab-runner created network with ipv6 support.
The docs specificaly mention This feature works only when the Docker daemon is configured with IPv6 enabled. To enable IPv6 support, set enable_ipv6 to true in the Docker configuration but this is misleading because it is directly followed by a link to the docker documentation.
Also the docker executors advanced configuration docs at https://docs.gitlab.com/runner/configuration/advanced-configuration.html#the-runnersdocker-section do not include any info about the required enable_ipv6 option\parameter\flag.
The info that helped me successfully activate ipv6 for the FF_NETWORK_PER_BUILDis buried in a comment of the related MR3583.
!3583 (comment 1123948749)
Further details
This is the info which is missing or not clear:
EnableIPv6 bool toml:"enable_ipv6,omitempty" json:"enable_ipv6" long:"enable-ipv6" description:"Enable IPv6 for automatically created networks. This is only takes affect when the feature flag FF_NETWORK_PER_BUILD is enabled."
Proposal
I solved it by adding the enable_ipv6 option to the gitlab-runner config.toml:
[[runners]]
[runners.docker]
enable_ipv6 = true
This and probably other ways on how to enable it should be part of the document https://docs.gitlab.com/runner/executors/docker.html#create-a-network-for-each-job
Also include this option and its description in the document https://docs.gitlab.com/runner/configuration/advanced-configuration.html#the-runnersdocker-section