Temporary failure in name resolution [Errno -3] with Docker
I just did sudo service docker restart
and it worked after. Definitely worth a shot before jumping in to modify your configurations.
I got the same problem with Ubuntu 16.04 and Docker version 17.09.0-ce.I don't think disabling dnsmasq
is the right solution.
Here is how I solved it:
For Ubuntu
Edit /etc/default/docker and add your DNS server to the following line:
Example
DOCKER_OPTS="--dns 8.8.8.8 --dns 10.252.252.252"
Reference:Network calls fail during image build on corporate network
On fedora 32 it was problem with firewall. Following command resolved issue:
$firewall-cmd --permanent --zone=trusted --add-interface=docker0$firewall-cmd --reload