Runner binary does not resolve host from mDNS (zeroconfig)
I have a demo environment that I use to give talks runnings as vm in Fusion on my mac. I have the vahi-daemon (zeroconfig) installed on the gitlab vm, so it can be pinged as git.local...
root@runner1:/etc/gitlab-runner# ping -c 4 git.local
PING git.local (192.168.80.117) 56(84) bytes of data.
64 bytes from git.local (192.168.80.117): icmp_seq=1 ttl=64 time=0.530 ms
64 bytes from git.local (192.168.80.117): icmp_seq=2 ttl=64 time=0.484 ms
64 bytes from git.local (192.168.80.117): icmp_seq=3 ttl=64 time=0.454 ms
64 bytes from git.local (192.168.80.117): icmp_seq=4 ttl=64 time=0.457 ms
--- git.local ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3002ms
rtt min/avg/max/mdev = 0.454/0.481/0.530/0.034 ms
root@runner1:/etc/gitlab-runner#
However, if I try to run the runner, it cannot find the host...
root@runner1:/etc/gitlab-runner# gitlab-runner run
WARNING: Checking for builds... failed runner=84c9862e status=couldn't execute POST against https://git.local/ci/api/v1/builds/register.json: Post https://git.local/ci/api/v1/builds/register.json: dial tcp: lookup git.local on 8.8.8.8:53: no such host
WARNING: Checking for builds... failed runner=84c9862e status=couldn't execute POST against https://git.local/ci/api/v1/builds/register.json: Post https://git.local/ci/api/v1/builds/register.json: dial tcp: lookup git.local on 8.8.8.8:53: no such host
WARNING: Checking for builds... failed runner=84c9862e status=couldn't execute POST against https://git.local/ci/api/v1/builds/register.json: Post https://git.local/ci/api/v1/builds/register.json: dial tcp: lookup git.local on 10.102.80.20:53: no such host
WARNING: Checking for builds... failed runner=84c9862e status=couldn't execute POST against https://git.local/ci/api/v1/builds/register.json: Post https://git.local/ci/api/v1/builds/register.json: dial tcp: lookup git.local on 10.102.80.20:53: no such host
^CWARNING: Requested service stop: interrupt builds=0
All workers stopped. Can exit now builds=0
but if I add the ip to the hosts file then it works...
root@runner1:/etc/gitlab-runner# echo "192.168.80.117 git.local" >> /etc/hosts
root@runner1:/etc/gitlab-runner# gitlab-runner run
...
^CWARNING: Requested service stop: interrupt builds=0
All workers stopped. Can exit now builds=0
I don't think that this is an nsswitch.conf thing, but maybe I am missing some configuration to tell go to use the hosts file?
I have tried to search about mDNS & Go Lang, but I only find mini mDNS servers that people have written.
Is this a bug or do I have something misconfigured?