Skip to content
This repository has been archived by the owner on Aug 1, 2024. It is now read-only.

Incomplete cleanup / Cost trap #276

Closed
DC4JG opened this issue Aug 17, 2021 · 2 comments · Fixed by #592
Closed

Incomplete cleanup / Cost trap #276

DC4JG opened this issue Aug 17, 2021 · 2 comments · Fixed by #592
Assignees
Labels
effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. good first issue Related to contributions. See CONTRIBUTING.md in-progress Issue is being actively worked on. p1

Comments

@DC4JG
Copy link

DC4JG commented Aug 17, 2021

The workshop and CDK itself lack information about how to clean up correctly and which cost may occur.

As stated in #126 and ignored for years in aws/aws-cdk#986, the user is left with a DynamoDB table, S3 bucket, CloudWatch logs and CloudFormation stack after finishing the workshop, without knowing about their existence.

This is a dark pattern (some may call it worse) as the user acts in good faith and in compliance with the cleanup section, yet will be left in an unclean state for redeployment and could be charged for resources he thought were destroyed.

I suggest the following steps:

  • add a clear warning about potentially occurring costs (upfront, users may not complete the workshop)
  • add description how/where to find an overview about all things which will/might create charges (e.g. in AWS Console)
  • extend the code examples about information on the RemovalPolicy options
  • implement and include the cdk bootstrap --destroy command
@ryparker ryparker added effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. good first issue Related to contributions. See CONTRIBUTING.md p1 labels Aug 19, 2021
@ryparker
Copy link
Contributor

ryparker commented Aug 19, 2021

Hey @DC4JG 👋 Thanks for bringing this up.

I agree that this could be confusing for new users and should be improved.

These action items would be a great first issue for anyone looking to contribute:

  • add a clear warning about potentially occurring costs (upfront, users may not complete the workshop)
  • add description how/where to find an overview about all things which will/might create charges (e.g. in AWS Console)

These action items I believe could be their own issues/PRs and could be implemented after the others:

  • extend the code examples about information on the RemovalPolicy options
  • implement and include the cdk bootstrap --destroy command

I'm marking this as p1 which means it has been prioritized as important, although please keep in mind that we do have a large number of issues at the moment (across all CDK repos). It may be some time before we are able to solve this particular issue. We use +1s to help us prioritize our work, and as always we are happy to take contributions if anyone is interested to pick this up and submit a PR.

@DC4JG
Copy link
Author

DC4JG commented Oct 12, 2021

Found a general (overkill) solution for all AWS issues regarding incomplete cleanup, borked CDK deployments, being unable to see what is deployed across the globe, generating cost and everything else like e.g. automatically hitting the big red button if something threatens to financially ruin you due to not being able to limit cost efficiently.

The community has created an AWS nuke, use carefully.

@peterwoodworth peterwoodworth self-assigned this Jun 15, 2022
@peterwoodworth peterwoodworth added the in-progress Issue is being actively worked on. label Jun 15, 2022
github-actions bot pushed a commit that referenced this issue Jul 13, 2022
<!--
Explain what changed and why.

Please read the [Contribution guidelines][1] and follow the pull-request
checklist.

[1]: https://github.com/aws-samples/aws-cdk-intro-workshop/blob/master/CONTRIBUTING.md
-->

Fixes #276 <!-- Please create a new issue if none exists yet -->

---

By submitting this pull request, I confirm that my contribution is made under the terms of the [Apache 2.0 license].

[Apache 2.0 license]: https://www.apache.org/licenses/LICENSE-2.0
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. good first issue Related to contributions. See CONTRIBUTING.md in-progress Issue is being actively worked on. p1
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants