22 lines
912 B
Terraform
22 lines
912 B
Terraform
|
resource "aws_cloudwatch_metric_alarm" "tgw-PacketDropCountNoRoute" {
|
||
|
alarm_name = "${var.cw-alarm-prefix}:TGW:PacketDropCountNoRoute:${var.tgw-id}"
|
||
|
comparison_operator = "GreaterThanThreshold"
|
||
|
evaluation_periods = "2"
|
||
|
metric_name = "PacketDropCountNoRoute"
|
||
|
period = "300"
|
||
|
statistic = "Average"
|
||
|
threshold = var.threshold-PacketDropCountNoRoute
|
||
|
alarm_description = "TGW:PacketDropCountNoRoute"
|
||
|
namespace = "AWS/TransitGateway"
|
||
|
insufficient_data_actions = []
|
||
|
actions_enabled = var.actions-enabled
|
||
|
alarm_actions = [var.sns-targets.alarm-actions-standard]
|
||
|
ok_actions = [var.sns-targets.alarm-actions-standard]
|
||
|
dimensions = {
|
||
|
TransitGateway = var.tgw-id
|
||
|
}
|
||
|
tags = var.default-tags
|
||
|
lifecycle {
|
||
|
ignore_changes = [tags]
|
||
|
}
|
||
|
}
|