ECS Service Cannot Connect: CloudMap vs. ECS Namespace

0

I have 2 ECS Services; one is a webserver, the other a Redis server. Both run as Fargate instances in the same ECS Cluster. The webserver cannot connect to redis. The ECS Namespace 'app.geoapp.local' shows both services: geo-webserver and app-redis (discovery name = redis-sc). So geo-webserver should be able to resolve app.geoapp.local because it is a member. But it cannot connect to redis using redis://app.geoapp.local:6379 with the error: "Cannot resolve app.geoapp.local." It connects OK to redis using the internal ip: redis://ip-10-0-1-111.us-west-2.compute.internal:6379, so likely not an SG issue. Also, DNS is enabled on the VPC. So why can't the webserver resolve app.geoapp.local? Looking at the same namespace 'app.geoapp.local' in CloudMap console, it shows different services: 'redis' and 'redis-sc,' but no 'geo-webserver.' Is that normal, CloudMap and ECS Namespaces different? I could "Create Service" in CloudMap and add the webserver manually, but would that overwrite the service already listed in the ECS Namespaces version or create a separate instance? I'd like to specify that webserver DependsOn redis, but I don't see how to do that other than manually editing the CloudFormation template. Any ideas on what I should try? Thanks!

답변 없음

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

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

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

관련 콘텐츠