Call ECS Service from Lambda

0

Hi Team, how can I call an ecs service from a lambda function. Both are in the same VPC and private subnet. ECS Services should communicate through Service Connect, but how can a Lambda function call an ECS Service? My plan is to create an API GW which redirects the requests to the ALB. ALB will route traffic with path redirecting to the ECS Services. So my question is: How can a Lambda Function call an ECS Service without involving API GW and in best case also ALB. Is there any option to discover ECS Services within the Lambda?

1 Risposta
0

Hello!

Service Connect still uses Cloud Map as a service registry. You can use Cloud Map's discover-instances API to resolve the IP addresses of your ECS workloads, and connect to them directly.

Is this what you are looking for?

profile pictureAWS
con risposta 2 mesi fa

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande