Skip to content

Commit

Permalink
fix: enable kms key rotation as default (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ic3w0lf authored Jun 12, 2023
1 parent 9d058d6 commit 7f466cd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,13 +84,13 @@ No outputs.

- resource.aws_cloudwatch_log_metric_filter.main (main.tf#24)
- resource.aws_cloudwatch_metric_alarm.main (main.tf#38)
- resource.aws_kms_alias.main (main.tf#69)
- resource.aws_kms_alias.main (main.tf#71)
- resource.aws_kms_key.main (main.tf#59)
- resource.aws_sns_topic.main (main.tf#108)
- resource.awscc_chatbot_slack_channel_configuration.main (main.tf#118)
- resource.aws_sns_topic.main (main.tf#110)
- resource.awscc_chatbot_slack_channel_configuration.main (main.tf#120)
- data source.aws_caller_identity.current (main.tf#18)
- data source.aws_cloudwatch_log_group.cloudtrail (main.tf#20)
- data source.aws_iam_policy_document.kms (main.tf#76)
- data source.aws_iam_policy_document.kms (main.tf#78)

# Examples
### Complete
Expand Down
6 changes: 4 additions & 2 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,11 @@ resource "aws_cloudwatch_metric_alarm" "main" {
resource "aws_kms_key" "main" {
count = var.sns_kms_master_key_id == null ? 1 : 0

description = "KMS key for CloudTrail alerts SNS topic."
description = "KMS key for CloudTrail alerts SNS topic."
policy = data.aws_iam_policy_document.kms[0].json

deletion_window_in_days = 7
policy = data.aws_iam_policy_document.kms[0].json
enable_key_rotation = true

tags = var.tags
}
Expand Down

0 comments on commit 7f466cd

Please sign in to comment.