"Error - ENOENT" while creating a lambda function via cdk

0

I have a node js project which used as a lambda authorizer in AWS. The node project structure will be like below

/authorizer
    /lib
       -index.js
-package.json
-node_modules
-package.lock.json

I am creating a CDK in typescript to create the lambda function as shown below. I have given the "entry" value as the path of "index.js".

Enter image description here

But I am getting this below error after that line Enter image description here

Can you guide me, what exactly missing here? any issue with bundling?

已提問 2 年前檢視次數 1314 次
1 個回答
0

Reading the docs https://docs.aws.amazon.com/cdk/api/v1/docs/aws-lambda-nodejs-readme.html#local-bundling as if esbuild is not available it will try to use docker to build. Which looks to be why the error is coming up?

AWS
已回答 2 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南