vagrant-docker-vm icon indicating copy to clipboard operation
vagrant-docker-vm copied to clipboard

DNS-Resolve inside DEV-VM is not working with bento/ubuntu-16.04.5

Open mediaessenz opened this issue 6 years ago • 2 comments

Because of this problem, all docker pull requests fail with this error:

Error response from daemon: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on 127.0.0.1:53: server misbehaving

When trying to log into the vagrant box using vargrant ssh and enter ping google.de the result is host unknown

I have an older DEV-VM installation with Bento/Ubuntu 16.04.3 running, which dosn't have this problem.

One (temporary) fix is to add a public dns server (eg. google dns 8.8.8.8) to the /etc/resolv.cnf file inside the build devvm.

mediaessenz avatar Nov 10 '18 16:11 mediaessenz

I could reproduce the problem also without using any webdevops stuff when using bento/ubuntu-16.04


My workaround is to add the file <gitProjectRootFolder>/customization/etc/dnsmasq.d/upstream with the following content:

server=10.211.55.1
server=8.8.4.4
server=8.8.8.8

The first line depends on your vagrant provider. For me, I use Parallels and the automatically created shared network is 10.211.55.x. The 2nd and 3rd is the google dns.

The file is automatically created if you run a vagrant provision on your vagrant-docker-vm.

josefglatz avatar Nov 16 '18 11:11 josefglatz

Today, I can't reproduce the problem in a clean vagrant environment with bento/ubuntu-16.04

josefglatz avatar Nov 16 '18 11:11 josefglatz