Failed cdk deploy/delete actions should try to tell me why
See original GitHub issueDeleting a “demo” stack that contains a bucket with removalPolicy: cdk.RemovalPolicy.Destroy
$ cdk destroy DemoBucketStack
...
❌ DemoBucketStack: destroy failed Error: The stack named DemoBucketStack is in a failed state: DELETE_FAILED (The following resource(s) failed to delete: [Bucket83908E77]. )
at waitFor (/Users/mp/.nvm/versions/node/v10.13.0/lib/node_modules/aws-cdk/lib/api/util/cloudformation.ts:144:13)
at process._tickCallback (internal/process/next_tick.js:68:7)
The stack named DemoBucketStack is in a failed state: DELETE_FAILED (The following resource(s) failed to delete: [Bucket83908E77]. )
Checking the CFN, I see:
The bucket you tried to delete is not empty (Service: Amazon S3; Status Code: 409; Error Code: BucketNotEmpty; ...)
The CDK toolkit should try to retrieve & display this information if an operation fails rather than relying on the user to use the aws CLI or console to discover it themselves.
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Troubleshooting common AWS CDK issues
AWS CloudFormation cannot delete a non-empty Amazon S3 bucket. If you set an Amazon S3 bucket's removal policy to DESTROY , and it...
Read more >AWS CDK Bootstrap Error and How To Fix It - Gerard Ketuma
Open the Cloudformation Service. Under Stacks, select the CDKToolkit stack and click on Delete . You will get a warning that deleting this ......
Read more >CDK stack stuck in UPDATE_ROLLBACK_FAILED - How to ...
You have to go into the console > Cloudformation > Your Stack > Stack Actions > Continue Rollback to see what cannot be...
Read more >awslabs/aws-cdk - Gitter
My attempts fails with errors about Parameters must have values, ... b/node_modules/@aws-cdk/app-delivery/lib/pipeline-deploy-stack-action.js index ...
Read more >Peculiar AWS CloudFormation failure | by Girish Deshpande
When you run cdk deploy with this change, the stack update will fail and it falls back to UPDATE_ROLLBACK_COMPLETE state. If you look...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It’s going to be there in the error message for the
DELETE_FAILED
of the bucket.We should probably capture the resource-specific error messages and propagate them for better usability.
I’m starting to feel that this whole “deploy a CloudFormation stack and do monitoring/progress reporting etc” could be its own NPM library.
This issue has not received any attention in 1 year. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.