From 2ecbd09873b7cdf262e0db83fdb6e5282def5715 Mon Sep 17 00:00:00 2001 From: William Shelley Date: Wed, 9 Oct 2024 16:34:12 +0100 Subject: [PATCH] feat: 5809 batch alarm email testing (#377) * fix: batch rule names * fix: naming and formatting * docs: update Terraform docs * fix: add name to targets * fix: naming syntax * docs: update Terraform docs * fix: more event renaming * feat: added sns email testing * docs: update Terraform docs --------- Co-authored-by: github-actions[bot] --- infra/terraform/modules/service/batch.tf | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/infra/terraform/modules/service/batch.tf b/infra/terraform/modules/service/batch.tf index 8da0fb420f..dd863b983d 100644 --- a/infra/terraform/modules/service/batch.tf +++ b/infra/terraform/modules/service/batch.tf @@ -164,7 +164,9 @@ module "eventbridge_sns" { source = "terraform-aws-modules/eventbridge/aws" version = "~> 3.7" - create_bus = false + create_bus = false + create_role = true + role_name = "vol-app-${var.environment}-batch-failures" rules = { "vol-app-${var.environment}-batch-failure-event" = { @@ -236,6 +238,13 @@ module "sns_batch_failure" { } } + subscriptions = { + "vol-app-${var.environment}-batch-failure-email" = { + protocol = "email" + endpoint = "william.shelley@dvsa.gov.uk" + } + } + tags = { "Name" = "vol-app-${var.environment}-aws-sns-batch-failure"