diff --git a/main.tf b/main.tf index 9c0d90c..35d94b6 100644 --- a/main.tf +++ b/main.tf @@ -9,7 +9,7 @@ terraform { module "apigw" { source = "armorfret/apigw-lambda/aws" - version = "0.8.0" + version = "0.9.0" source_bucket = var.lambda_bucket source_version = var.lambda_version @@ -27,6 +27,8 @@ module "apigw" { binary_media_types = [ "*/*", ] + + cloudwatch_retention_in_days = var.cloudwatch_retention_in_days } module "publish_user" { diff --git a/variables.tf b/variables.tf index 88ff86d..d6c6541 100644 --- a/variables.tf +++ b/variables.tf @@ -28,3 +28,9 @@ variable "hostname" { description = "Hostname to use for the site" type = string } + +variable "cloudwatch_retention_in_days" { + description = "Days to retain cloudwatch logs" + type = number + default = 30 +}