Created
January 17, 2020 16:23
-
-
Save hervekhg/e93cabf3a27c1bbaeeab9cded5f91198 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resource "aws_cloudwatch_event_rule" "daily" { | |
name = "daily_enforce_bucket_kms_encryption" | |
description = "run everyday" | |
#schedule_expression = "${var.cron_schedule_enforce_bucket_encryption} " | |
event_pattern = <<PATTERN | |
{ | |
"source": [ | |
"aws.s3" | |
], | |
"detail-type": [ | |
"AWS API Call via CloudTrail" | |
], | |
"detail": { | |
"eventSource": [ | |
"s3.amazonaws.com" | |
], | |
"eventName": [ | |
"CreateBucket" | |
] | |
} | |
} | |
PATTERN | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment