Skip to content

Failed Change Set Destroyer deletes failed change sets from CloudFormation stacks.

License

Notifications You must be signed in to change notification settings

mgorski-mg/aws-failed-change-sets-destroyer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AWS Failed Change Set Destroyer

Failed Change Set Destroyer deletes failed change sets from CloudFormation stacks.

Available on the AWS Serverless Application Repository - failed-change-sets-destroyer

Why is it helpful?

Deploying an unchanged stack creates failed change set which may lead to failure with the following error message:

An error occurred (LimitExceededException) when calling the CreateChangeSet operation: ChangeSet limit exceeded for stack ...

It means the maximum number of change sets for a stack was reached.

This lambda is removing all failed change sets so the error should not occur.

Getting Started

Prerequisites

Deployment

To deploy Failed Change Set Destroyer edit deploy.bat file and change

  • <stack-name> - new stack name
  • <s3-bucket-name> - s3 bucket name for code and template file needed for deployment of the AWS Lambda
  • <s3-bucket-prefix> - logical folder for the code and template file

Then run the Lambda.

Input Lambda Event

{
    "dry_run": true,
    "regions": ["us-west-1", "..."]
}

Default values

  • dry_run: true
  • regions: all regions

It is strongly recommended to use dry_run mode first!!

Scheduler

Failed Change Set Destroyer by default is scheduled every first day of the month.

The schedule can be changed by overriding SchedulerCronParameter.

The scheduler can be disabled using SchedulerEnabledParameter.

About

Failed Change Set Destroyer deletes failed change sets from CloudFormation stacks.

Topics

Resources

License

Stars

Watchers

Forks

Languages