Skip to content
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions infrastructure/lambda-send-feedback.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,18 @@ locals {
)
}

data "aws_ssm_parameter" "itoc_feedback_testing_teams_webhook" {
name = "/ndr/itoc/feedback_testing/teams_webhook"
}

data "aws_ssm_parameter" "itoc_feedback_testing_ods_codes" {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
data "aws_ssm_parameter" "itoc_feedback_testing_ods_codes" {
data "aws_ssm_parameter" "itoc_testing_ods_codes" {

name = "/auth/org/ods_code/allowed_list_itoc"
}

data "aws_ssm_parameter" "itoc_feedback_testing_slack_channel_id" {
name = "/ndr/itoc/feedback_testing/slack/channel_id"
}

module "send-feedback-gateway" {
source = "./modules/gateway"
api_gateway_id = aws_api_gateway_rest_api.ndr_doc_store_api.id
Expand Down Expand Up @@ -84,6 +96,10 @@ module "send-feedback-lambda" {
FROM_EMAIL_ADDRESS = local.ses_feedback_sender_email_address
EMAIL_SUBJECT = "Digitised Lloyd George feedback"
EMAIL_RECIPIENT_SSM_PARAM_KEY = local.feedback_recipient_list_ssm_param_key
ITOC_TESTING_TEAMS_WEBHOOK = data.aws_ssm_parameter.itoc_feedback_testing_teams_webhook.value
ITOC_TESTING_ODS_CODES = data.aws_ssm_parameter.itoc_feedback_testing_ods_codes.value
ITOC_TESTING_CHANNEL_ID = data.aws_ssm_parameter.itoc_feedback_testing_slack_channel_id.value
ITOC_TESTING_SLACK_BOT_TOKEN = data.aws_ssm_parameter.slack_alerting_bot_token.value
}
depends_on = [
aws_api_gateway_rest_api.ndr_doc_store_api,
Expand Down
2 changes: 1 addition & 1 deletion infrastructure/modules/lambda/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ resource "aws_lambda_function" "lambda" {
environment {
variables = var.lambda_environment_variables
}

vpc_config {
subnet_ids = var.vpc_subnet_ids
security_group_ids = var.vpc_security_group_ids
Expand Down
3 changes: 3 additions & 0 deletions infrastructure/modules/vpc/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ resource "aws_default_security_group" "default" {
vpc_id = local.is_production ? aws_vpc.vpc[0].id : data.aws_vpc.vpc[0].id
ingress = []
egress = []
tags = {
Workspace = "core"
}
}

data "aws_internet_gateway" "ig" {
Expand Down