Skip to content

Commit

Permalink
add object_lock_enabled to aws_s3_bucket resource (#17)
Browse files Browse the repository at this point in the history
  • Loading branch information
jaegarpoon authored Jan 7, 2025
1 parent f2015b3 commit 19eab40
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
4 changes: 3 additions & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ resource "aws_s3_bucket" "main" {
for_each = var.s3_buckets

bucket = each.value.bucket


object_lock_enabled = var.object_lock_enabled

tags_all = var.tags
}

Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ variable "path" {
default = "/"
}

variable "object_lock_enabled" {
description = "(Optional) Enable object lock for the S3 bucket"
type = bool
default = false
}

variable "tags" {
description = "(Optional) A mapping of tags to assign to the bucket."
type = map(string)
Expand Down

0 comments on commit 19eab40

Please sign in to comment.