Lambda Functions raise forbidden error until stack deleted and redeployed

0

Currently if I add a new Lambda Function to the SAM Template and Route to it through an API Gateway (WebSocket type), it will raise a 'Forbidden' error until I manually delete the entire Stack and redeploy the SAM Template.

The Lambda Function, API Gateway and routing, and Permissions are all established in the SAM Template and work just fine on a clean deploy (no existing stack). But, if I add a new Lambda Function to the SAM Template with all the previously mentioned plumbing, it will not be accessible until I delete the stack manually, then re-run the deployment.

Is there any guidance to ensure that every deployment, where the plumbing is correct, will result in accessible Lambda Functions?

asked 4 years ago291 views
1 Answer
0

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigatewayv2-stage.html

AutoDeploy defaults to false

Add the AutoDeploy property to the Stage and set to true and the problem is solved.

answered 4 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions