Skip to content

Commit dc147d4

Browse files
feat: add EKS/RDS Extended Support Eventbridge rules
1 parent 96c7073 commit dc147d4

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

eventbridge.tf

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# EventBridge Rule (RDS Extended Support Billing)
2+
resource "aws_cloudwatch_event_rule" "rds_extended_support_billing" {
3+
name = "rds-extended-support-billing-notification"
4+
description = "Captures AWS Billing notifications for RDS Extended Support"
5+
6+
event_pattern = jsonencode({
7+
"source" : ["aws.health"],
8+
"detail" : {
9+
"eventTypeCode" : ["AWS_BILLING_NOTIFICATION"],
10+
"eventDescription" : [{
11+
"latestDescription" : [{
12+
"wildcard" : ["*RDS Extended Support*"]
13+
}]
14+
}]
15+
}
16+
})
17+
}
18+
19+
resource "aws_cloudwatch_event_target" "rds_extended_support_billing" {
20+
rule = aws_cloudwatch_event_rule.rds_extended_support_billing.name
21+
arn = local.sns_topic_arn
22+
}
23+
24+
# EventBridge Rule (EKS Extended Support Billing)
25+
resource "aws_cloudwatch_event_rule" "eks_extended_support_billing" {
26+
name = "rds-extended-support-billing-notification"
27+
description = "Captures AWS Billing notifications for EKS Extended Support"
28+
29+
event_pattern = jsonencode({
30+
"source" : ["aws.health"],
31+
"detail" : {
32+
"eventTypeCode" : ["AWS_BILLING_NOTIFICATION"],
33+
"eventDescription" : [{
34+
"latestDescription" : [{
35+
"wildcard" : ["*EKS Extended Support*"]
36+
}]
37+
}]
38+
}
39+
})
40+
}
41+
42+
resource "aws_cloudwatch_event_target" "eks_extended_support_billing" {
43+
rule = aws_cloudwatch_event_rule.rds_extended_support_billing.name
44+
arn = local.sns_topic_arn
45+
}

0 commit comments

Comments
 (0)