Skip to content

Commit

Permalink
Merge pull request #35 from nearform/hotfix/lambda-sms-remove
Browse files Browse the repository at this point in the history
Hotfix/lambda sms remove
  • Loading branch information
dgonzalez authored Dec 18, 2020
2 parents 2f14bd1 + c725bc0 commit ee86e09
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions lambda-sms-remove.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
module "sms_remove" {
source = "./modules/lambda"
enable = contains(var.optional_lambdas_to_include, "sms-remove")
name = format("%s-sms-remove", module.labels.id)

aws_parameter_arns = [
aws_ssm_parameter.sms_template.arn,
aws_ssm_parameter.sms_url.arn,
]
aws_secret_arns = data.aws_secretsmanager_secret_version.sms.*.arn
config_var_prefix = local.config_var_prefix
handler = "sms-remove.handler"
kms_reader_arns = [aws_kms_key.sqs.arn]
layers = lookup(var.lambda_custom_runtimes, "sms", "NOT-FOUND") == "NOT-FOUND" ? null : var.lambda_custom_runtimes["sms"].layers
log_retention_days = var.logs_retention_days
memory_size = var.lambda_sms_memory_size
runtime = lookup(var.lambda_custom_runtimes, "sms", "NOT-FOUND") == "NOT-FOUND" ? var.lambda_default_runtime : var.lambda_custom_runtimes["sms"].runtime
security_group_ids = [module.lambda_sg.id]
subnet_ids = module.vpc.private_subnets
tags = module.labels.tags
timeout = 900
cloudwatch_schedule_expression = "cron(0 3 * * ? *)"
}

0 comments on commit ee86e09

Please sign in to comment.