I just tried debian docker, the DNS is not available:
wfg@debian ~% ping host.docker.internal ping: host.docker.internal: Name or service not known
it's the host machine: crystal-ci I test on my own server, add "host_ip host.docker.internal" in /etc/hosts, then execute "ping host.docker.internal" in docker container, it will goes well"
Don't rely on manual configs in the host side.
How about this in docker?
wfg@debian ~% ip route get 1.2.3.4 1.2.3.4 via 172.17.0.1 dev eth0 src 172.17.0.61 uid 1000 cache => wfg@debian ~% ip route get 1.2.3.4 | awk '{print $3; exit}' 172.17.0.1
Thanks, Fengguang