Skip to content

Commit

Permalink
Support disabling versioning in private buckets (#122)
Browse files Browse the repository at this point in the history
  • Loading branch information
mbarrien authored Sep 16, 2019
1 parent 96ea06d commit 6923e1b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.18.2
0.19.1
1 change: 1 addition & 0 deletions aws-s3-private-bucket/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
|------|-------------|:----:|:-----:|:-----:|
| bucket\_name | | string | n/a | yes |
| bucket\_policy | | string | `""` | no |
| enable\_versioning | Keep old versions of overwritten S3 objects. | bool | `true` | no |
| env | | string | n/a | yes |
| owner | | string | n/a | yes |
| project | | string | n/a | yes |
Expand Down
2 changes: 1 addition & 1 deletion aws-s3-private-bucket/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ resource "aws_s3_bucket" "bucket" {
policy = "${data.aws_iam_policy_document.bucket_policy.json}"

versioning {
enabled = true
enabled = var.enable_versioning
}

# TODO
Expand Down
6 changes: 6 additions & 0 deletions aws-s3-private-bucket/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,9 @@ variable "service" {
variable "owner" {
type = "string"
}

variable "enable_versioning" {
type = bool
description = "Keep old versions of overwritten S3 objects."
default = true
}

0 comments on commit 6923e1b

Please sign in to comment.