File tree Expand file tree Collapse file tree 1 file changed +40
-0
lines changed Expand file tree Collapse file tree 1 file changed +40
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ layout : " aws"
3
+ page_title : " AWS - aws_s3_bucket_versioning"
4
+ sidebar_current : " docs-aws-s3-bucket-versioning"
5
+ description : |-
6
+ Provides a resource for controlling S3 bucket versioning
7
+ ---
8
+
9
+ # aws_s3_bucket_versioning
10
+
11
+ Provides a resource for controlling versioning on an [ S3 bucket] [ 1 ] . Note that this
12
+ may conflict with the ` versioning ` block of an [ aws_s3_bucket] [ 1 ] if the settings are
13
+ not the same.
14
+
15
+ ## Example Usage
16
+
17
+ ``` hcl
18
+ resource "aws_s3_bucket" "b" {
19
+ bucket = "example-bucket"
20
+ acl = "private"
21
+ }
22
+
23
+ resource "aws_s3_bucket_versioning" "versioning_example" {
24
+ bucket = "${aws_s3_bucket.b.id}"
25
+ enabled = true
26
+ }
27
+ ```
28
+
29
+ ## Argument Reference
30
+
31
+ The following arguments are supported:
32
+
33
+ * ` bucket ` - (Required) The name of the S3 bucket
34
+ * ` enabled ` - (Required) Whether to enable versioning on the bucket
35
+
36
+ ## Deletion
37
+
38
+ Deleting this resource will disable versioning on the bucket.
39
+
40
+ [ 1 ] : /docs/providers/aws/r/s3_bucket.html
You can’t perform that action at this time.
0 commit comments