Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Exclude Resources by Tag Existence #822

Open
ErezWeiss opened this issue Dec 22, 2024 · 1 comment
Open

Feature Request: Exclude Resources by Tag Existence #822

ErezWeiss opened this issue Dec 22, 2024 · 1 comment

Comments

@ErezWeiss
Copy link

Feature Request: Exclude Resources by Tag Existence in Cloud Nuke

Current Behavior:
Cloud Nuke currently supports excluding resources based on a specified key only if its value is "true".

Feature Request:
Add support for excluding resources based on the existence of a tag key, regardless of its value.

Use Case:
For example, if a resource has the tag Component: rds, I would like to exclude it by specifying isTagExist: Component. This ensures that all resources with the key Component (regardless of its value) are excluded from nuking.

Proposed Solution:
Introduce a new parameter isTagExist that accepts a tag key. If the specified key exists on a resource, the resource will be excluded.

Benefits:

  • Provides more flexibility for users to manage exclusions.
  • Simplifies scenarios where values of tags are dynamic or irrelevant.

Example Configuration:

excludeTags:
  isTagExist: Component

Would exclude any resource with the tag Component present, such as:

  • Component: rds
  • Component: database
  • Component: test

Let me know if more details are needed!

@ErezWeiss ErezWeiss changed the title Add the ability to exclude by isTagExist Feature Request: Exclude Resources by Tag Existence Dec 22, 2024
@wakeful
Copy link
Contributor

wakeful commented Dec 22, 2024

hey, @ErezWeiss

Just to clarify your request: should that exclusion be a global filter (applied across all resources), or are you looking for the possibility to set this per resource, e.g.?

s3:
  exclude:
    ifTagExist: Component

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants