AWS ECS & CloudMap "no such host"

1.2k Views Asked by At

I have an ECS cluster setup with a container that runs a microservice hosting a public and private HTTP server.

I have the public HTTP server being connected through an Elastic Load Balancer which is working correctly, however the internal HTTP server is being routed via AWS Cloud Map and Route 53 with a private hosted zone.

AWS Cloud Map finds the instance correctly, however when trying to access the private endpoint from another ECS task I get a no such host error.

Any suggestions on what could be the cause?

Thanks!

1

There are 1 best solutions below

0
Mawardy On

For me it's resolved that DNS Hostnames and DNS resolution are enabled in your VPC settings,

Go to your VPC dashboard then press on "Actions" button then

Press Edit DNS hostnames

Edit DNS hostnames

Check the "Enable" checkbox

Enable DNS hostnames

and same goes for DNS resolution.