https://serverless-stack.com/ logo
#help
Title
# help
j

Jędrzej Kuryło

02/03/2022, 2:10 PM
hey, what's the best way to debug NextjsSite resource? I've got a simple app that works just fine locally with
next dev
and
next start
, but when deployed I get 503, so I guess the app returned some sort of error. I'm having trouble finding any trace of error logs in AWS... I can see 3 resources of type
Custom::SSTEdgeLambda
created, my guess is that it's one of those that executes my app logic, but I don't see a corresponding log group in Cloudwatch
Copy code
CREATE_COMPLETE | Custom::SSTEdgeLambda | xxxImageEdgeLambda6D1A8C9F
CREATE_COMPLETE | Custom::SSTEdgeLambda | xxxMainEdgeLambdaCD2001DA
CREATE_COMPLETE | Custom::SSTEdgeLambda | xxxApiEdgeLambda3EC77306
Any idea how to figure out why the app's failing?
j

Jay

02/06/2022, 11:08 PM
@Frank any idea how to debug this?
f

Frank

02/24/2022, 2:09 AM
Yeah, it’s a bit tricky to locate the logs for the Edge Lambda functions. If you: • go to the CloudWatch console • change the region to the region from where the request was made (if you are testing it, it’s the region closest to you, not the Lambda’s region) • look for the log group with the name of the
xxxMainEdgeLambdaCD2001DA
function
Let me know if that works for you.
5 Views