5

I know this error relate to DNS lookup timed out error, means it is a network connectivity error or proxy related error. However I do not know how to fix it.

I use docker-compose.yml ,and 3 containers are inside.

This is my docker-compose.yml. as link

docker-compose.yml

I created 2 networks to divide external and internal network. All request from the client are going through Nginx,port:8090 which only is expose to the internet.

The issue is that I got the error message "getaddrinfo EAI_AGAIN exampleAuth.auth0.com:443" when I send request to verify users from API container(internal network).

Here is what I have tried to so far

  • I tried to add DNS 8.8.8.8 in docker demon
  • ping 8.8.8.8 from API container (it does not work)
  • ping 8.8.8.8 from Nginx container (it does work)
  • ping between internal and default entwork is find

Do you guys have any idea?

Gil
  • 105
  • 2
  • 5
  • 12

4 Answers4

1

For clarification: Don't ever use node:alpine for network consuming applications. I experienced same issue and after hours struggling with, using node latest resolved the issue.

vahid sabet
  • 485
  • 1
  • 6
  • 16
0

Changing in my Dockerbuild alpine to stretch-slim (debian) has solved a similar issue of yours.

Ilan Schemoul
  • 1,461
  • 12
  • 17
0

I've experienced the same issue from within an alpine container when running npm install. In my case the network had changed, stopping and restarting the container solved the issue.

docker-compose down
docker-compose up

Source: https://github.com/moby/moby/issues/32106

Diego P. Steiner
  • 2,075
  • 1
  • 15
  • 14
0

I was facing the same issue. The solution is to add DNSes to daemon.json. This solution won't take affect unless you restart docker on machine. So restarting is essential for this issue to be resolved.

Asad Awan
  • 43
  • 1
  • 1
  • 4