Closed vezaynk closed 1 year ago
Hey @vezaynk, if you're deploying any of the 'serverless' templates in the .NET tooling then you'll need to deploy them using:
dotnet lambda deploy-serverless
This deploys the function through CloudFormation using the contents of the serverless.template file. It's this serverless.template file that gets auto-generated by the .NET tooling.
If you wanted to deploy a different way, let's say through
dotnet lambda deploy-function
You could take the details generated automatically in the serverless.template file and pass them into the dotnet lambda deploy-function wizard. For example, to deploy the 'add' Lambda endpoint you would need a handler:
"Handler": "Serverless.Annotations::Serverless.Annotations.Functions_Add_Generated::Add",
dotnet lambda deploy-function
is meant for deploying a single Lambda function though, and you wouldn't get the API endpoint in front of it.
Could you try again using dotnet lambda deploy-serverless
?
@vezaynk Thanks for opening the issue. As @jeastham1993 mentioned, please try using dotnet lambda deploy-serverless
.
It works! Thank you!
Comments on closed issues are hard for our team to see. If you need more assistance, please either tag a team member or open a new issue that references this one. If you wish to keep having a conversation with other community members under this issue feel free to do so.
Describe the bug
I am trying out the .NET Annotations Lambda Framework (Preview) and am having issues using it.
I deploy:
And then I invoke via lambda url and get an internal error. When checking cloudwatch logs I see this:
Am I deploying it wrong?
Expected Behavior
Should return a method result
Current Behavior
Results 404
Reproduction Steps
Generate from template
serverless.Annotations
, deploy usingdotnet lambda deploy-function
.Possible Solution
No response
Additional Information/Context
No response
AWS .NET SDK and/or Package version used
Only the template
Targeted .NET Platform
Dotnet6
Operating System and version
Linux