Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save cat5inthecradle/66a09261e51d4303aa9fc94d5d2c8826 to your computer and use it in GitHub Desktop.

Select an option

Save cat5inthecradle/66a09261e51d4303aa9fc94d5d2c8826 to your computer and use it in GitHub Desktop.
Cloudformation change-set samples
# http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-changesets.html
# create it
aws cloudformation create-change-set \
--stack-name arn:aws:cloudformation:us-east-1:123456789012:stack/SampleStack/1a2345b6-0000-00a0-a123-00abc0abc000
--change-set-name SampleChangeSet \
--use-previous-template \
--parameters ParameterKey="InstanceType",UsePreviousValue=true ParameterKey="KeyPairName",UsePreviousValue=true ParameterKey="Purpose",ParameterValue="production"
# view it
aws cloudformation describe-change-set \
--change-set-name arn:aws:cloudformation:us-east-1:123456789012:changeSet/SampleChangeSet/1a2345b6-0000-00a0-a123-00abc0abc000
# execute it
aws cloudformation execute-change-set \
--change-set-name arn:aws:cloudformation:us-east-1:123456789012:changeSet/SampleChangeSet/1a2345b6-0000-00a0-a123-00abc0abc000
# delete it
aws cloudformation delete-change-set \
--change-set-name arn:aws:cloudformation:us-east-1:123456789012:changeSet/SampleChangeSet/1a2345b6-0000-00a0-a123-00abc0abc000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment