Skip to content

Commit c5fbab3

Browse files
committed
Added alarm for splunk s3 backup for delivery failures
1 parent 4d7b6cc commit c5fbab3

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

infrastructure/stacks/api-layer/cloudwatch_alarms.tf

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -491,3 +491,32 @@ resource "aws_cloudwatch_metric_alarm" "acm_expiry_alarms" {
491491

492492
alarm_actions = [aws_sns_topic.cloudwatch_alarms.arn]
493493
}
494+
495+
# Splunk backup S3 bucket delivery failure alarm
496+
resource "aws_cloudwatch_metric_alarm" "splunk_backup_delivery_failure" {
497+
alarm_name = "SplunkBackupS3DeliveryFailure"
498+
alarm_description = "Triggers when there is a delivery failure to the eli-splunk S3 bucket"
499+
namespace = "AWS/S3"
500+
metric_name = "DeliveryFailed"
501+
statistic = "Sum"
502+
period = 300 # 5 minutes
503+
evaluation_periods = 1
504+
threshold = 1
505+
comparison_operator = "GreaterThanOrEqualToThreshold"
506+
treat_missing_data = "notBreaching"
507+
508+
dimensions = {
509+
BucketName = "eli-splunk"
510+
StorageType = "AllStorageTypes"
511+
}
512+
513+
alarm_actions = [aws_sns_topic.cloudwatch_alarms.arn]
514+
515+
tags = {
516+
Environment = var.environment
517+
AlertType = "data-delivery"
518+
Service = "s3"
519+
Severity = "high"
520+
ManagedBy = "terraform"
521+
}
522+
}

0 commit comments

Comments
 (0)