I am using Colima to run docker engine on my mac. I was facing similar issue when pulling an image. I added nameserver 8.8.8.8
and nameserver 8.8.4.4.
in /etc/resolv.conf
file and restarted colima with command -> colima restart
. After that, I was able to pull the image.