Skip to content

Getting "EndpointConnectionError: Could not connect to the endpoint URL" #8052

Answered by bblommers
RajasGujarathi asked this question in Q&A
Discussion options

You must be logged in to vote

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 ThreadedMotoServer runs on the host system. host.docker.internal is 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. (Installed 1.27.0, AWS_ENDPOINT_URL only available in 1.28.0)

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@RajasGujarathi
Comment options

Answer selected by RajasGujarathi
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants