I have a little problem with a small serverless deployment. I accidentally deleted a LogGroup when cleaning up a previous deployment and now i’m unable to re-deploy one function of the setup.
Serverless Error ---------------------------------------
An error occurred while provisioning your stack: IamRoleLambdaExecution
- Template error: LogGroup /aws/lambda/photoservice-prod-getPhoto
doesn't exist.
When i manually create a LogGroup named /aws/lambda/photoservice-prod-getPhoto
i get the opposite error:
Serverless Error ---------------------------------------
An error occurred while provisioning your stack: GetPhotoLogGroup
- /aws/lambda/photoservice-prod-getPhoto already exists.
Is there a way to manually correct an error like this and get back to a consistent state? I already looked through the cloudformation templates, but can’t find any inconsistency with this function that would cause it to think it exists or is missing in the first place.
I could just delete and re-create the whole stack, but this is not really a solution for when the system is in use, so it would be good to know if and how it’s possible to fix it manually.