Getting "EndpointConnectionError: Could not connect to the endpoint URL" #8052
-
moto version - 5.0.13I am running a Moto Server and invoking a Lambda function, The invoked Lambda tries to make a ECS service call. However, I get Any suggestions? Related question: Additionally, if we pass |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
|
Hi @RajasGujarathi, the endpoint url would need to be set to The Lambda is executed within a Docker container, but the Did you have to do anything special with the boto3-version? If I'm executing the Lambda in Python 3.11, the installed boto3-version is too old and doesn't support the |
Beta Was this translation helpful? Give feedback.
-
|
For reference, the MRE that shows it works: (Note the system-call to update boto3 before executing the Lambda) |
Beta Was this translation helpful? Give feedback.
Hi @RajasGujarathi, the endpoint url would need to be set to
http://host.docker.internal:{port}in that case.The Lambda is executed within a Docker container, but the
ThreadedMotoServerruns on the host system.host.docker.internalis a Docker-specific hostname that indicates that whatever server it's trying to reach, is located on the host.Did you have to do anything special with the boto3-version? If I'm executing the Lambda in Python 3.11, the installed boto3-version is too old and doesn't support the
AWS_ENDPOINT_URL-variable yet. (Installed1.27.0, AWS_ENDPOINT_URL only available in1.28.0)