Skip to content

Commit

Permalink
Merge pull request #29 from trussworks/lh_set_retention
Browse files Browse the repository at this point in the history
Setting log_retention as var with default of 731 days
  • Loading branch information
mr337 authored Aug 5, 2020
2 parents 7b1af6c + 517eee0 commit c0353fe
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ module "bootstrap" {
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| account\_alias | The desired AWS account alias. | `string` | n/a | yes |
| log\_retention | Log retention of access logs of state bucket. | `number` | `90` | no |
| region | AWS region. | `string` | n/a | yes |

## Outputs
Expand Down
7 changes: 4 additions & 3 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,10 @@ module "terraform_state_bucket_logs" {
source = "trussworks/logs/aws"
version = "~> 8.0.1"

region = var.region
s3_bucket_name = local.logging_bucket
default_allow = false
region = var.region
s3_bucket_name = local.logging_bucket
default_allow = false
s3_log_bucket_retention = var.log_retention
}

#
Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,9 @@ variable "account_alias" {
description = "The desired AWS account alias."
type = string
}

variable "log_retention" {
description = "Log retention of access logs of state bucket."
default = 90
type = number
}

0 comments on commit c0353fe

Please sign in to comment.