UPD: added force_destroy support tp s3 bucket module
This commit is contained in:
parent
b0e174bcfa
commit
436b799ff1
@ -1,5 +1,6 @@
|
|||||||
resource "aws_s3_bucket" "this" {
|
resource "aws_s3_bucket" "this" {
|
||||||
bucket = var.bucket_name
|
bucket = var.bucket_name
|
||||||
|
force_destroy = var.bucket_force_destroy
|
||||||
}
|
}
|
||||||
|
|
||||||
resource "aws_s3_bucket_public_access_block" "block_public_access" {
|
resource "aws_s3_bucket_public_access_block" "block_public_access" {
|
||||||
|
@ -3,6 +3,12 @@ variable "bucket_name" {
|
|||||||
description = "Name of bucket"
|
description = "Name of bucket"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
variable bucket_force_destroy {
|
||||||
|
type = bool
|
||||||
|
default = false
|
||||||
|
description = "Indicates all objects should be deleted from the bucket when the bucket is destroyed."
|
||||||
|
}
|
||||||
|
|
||||||
variable "bucket_policy_json" {
|
variable "bucket_policy_json" {
|
||||||
type = string
|
type = string
|
||||||
default = "{}"
|
default = "{}"
|
||||||
|
Loading…
Reference in New Issue
Block a user