Connect to a container via ECS Service connect

0

Hi, I created dummy container and can connect to it via public ip. I don't want to use ip that is changed all the time. So I want to use a DNS name. I created ECS Service connect but I can't connect to it via browser: http://angular-app:80 My set up: Enter image description here

Should I have the ability to connect to it via terminal on my PC?

Thanks

1개 답변
1
수락된 답변

Hello.

Service Connect allows you to reference and connect services by logical name using the namespace provided by AWS Cloud Map for communication between ECS tasks, and automatically distributes traffic between ECS tasks without introducing or configuring a load balancer.
In other words, it is a function that allows Service Connect to allocate a private host name to tasks and allow the tasks to communicate with each other using that name.
Therefore, it is not possible to directly access "http://angular-app:80" from a browser that is not communicating between ECS.
https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-connect-concepts.html

If you want to access an ECS task from a browser, you need to use the public IP address of the task or link the ALB to the ECS task and access the ALB.
https://docs.aws.amazon.com/AmazonECS/latest/developerguide/create-application-load-balancer.html

profile picture
전문가
답변함 2달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠