내용으로 건너뛰기

Deploy nestjs app to lambda but keeps timeout

0

Hi,

I deployed a nestjs app to a lambda function but it never invoked successfully. Always showed me 502 internal server error.

I tested 'sam local start-apo', and it worked ok.

This app does not communicate to any other aws services, and no VPC was set up.

Tried api gateway and public function url, but both showed 502.

Here is the serverless.ts that defines the handler. Enter image description here

Here is the yaml file. Enter image description here

here is the log. Enter image description here

Please let me know if you need more information.

Thank you so much.

Chris

질문됨 3년 전546회 조회

1개 답변
1
수락된 답변

this issue has been solved. it's the MongoDB that was not connected properly.

답변함 3년 전

전문가

검토됨 3년 전

  • Do you have any more detail on this please? I have tried several different uri combinations, I am able to connect to it locally over the VPC via VPN, but not from Lambda

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

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

관련 콘텐츠