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

feat: Add usage example for monitoring alerts on KMS key versions #162

Merged

Conversation

romanini-ciandt
Copy link
Member

@romanini-ciandt romanini-ciandt commented Nov 8, 2024

The goal of this PR is to provide an example of an alert being sent when a KMS key version is marked to be deleted.

reclassify as chore as this doesn't include any "releasable" changes

BEGIN_COMMIT_OVERRIDE
chore: Add usage example for monitoring alerts on KMS key versions (#162)
END_COMMIT_OVERRIDE

@romanini-ciandt romanini-ciandt marked this pull request as ready for review November 12, 2024 19:02
@romanini-ciandt romanini-ciandt requested a review from a team as a code owner November 12, 2024 19:02
Copy link

@tdbhacks tdbhacks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is extremely cool, nicely done!!

I guess my only comment is that maybe it's worth to also offer a version (through another input variable) where the module doesn't necessarily create a new key version. But I guess this is an example and not a true standalone module, so feel free to ignore. I imagine one of the reasons to have it in there was to also make testing easier in terms of having a sample key ready to be destroyed, otherwise that part would have to be in the test logic itself. Other than that, LGTM!

We'll see if @erlanderlo has more to say :)

Copy link

@erlanderlo erlanderlo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm - good testing ideas.
mostly nits and few minor comments

examples/monitoring_alerts/README.md Outdated Show resolved Hide resolved
examples/monitoring_alerts/main.tf Outdated Show resolved Hide resolved
examples/monitoring_alerts/main.tf Show resolved Hide resolved
examples/monitoring_alerts/variables.tf Show resolved Hide resolved
@romanini-ciandt
Copy link
Member Author

This is extremely cool, nicely done!!

I guess my only comment is that maybe it's worth to also offer a version (through another input variable) where the module doesn't necessarily create a new key version. But I guess this is an example and not a true standalone module, so feel free to ignore. I imagine one of the reasons to have it in there was to also make testing easier in terms of having a sample key ready to be destroyed, otherwise that part would have to be in the test logic itself. Other than that, LGTM!

We'll see if @erlanderlo has more to say :)

Thanks for your review!
Yeah, I'm creating the key in the example in order to get the testing process easier and more effective (because we can actually delete the key that was previously created and test the expected result.)

I added a comment with instructions for users wanting to use an existing KMS key.

@romanini-ciandt
Copy link
Member Author

@apeabody could you PTAL on this PR?
It's approved by @erlanderlo. If you don't have any additional point, we'd like to merge it, please.

Copy link
Contributor

@apeabody apeabody left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Already reviewed

@apeabody apeabody merged commit f863889 into terraform-google-modules:master Nov 27, 2024
4 checks passed
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

Successfully merging this pull request may close these issues.

4 participants