You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Timeout if SQS policy created without explicit version in notification module ([#321](https://github.com/terraform-aws-modules/terraform-aws-s3-bucket/issues/321)) ([1b1ca55](https://github.com/terraform-aws-modules/terraform-aws-s3-bucket/commit/1b1ca553669bbca0a0c42378a1bab3af5302df4f))
* Added Account-level Public Access Block module, and minor fixes as fallback ([#299](https://github.com/terraform-aws-modules/terraform-aws-s3-bucket/issues/299)) ([69f0f4e](https://github.com/terraform-aws-modules/terraform-aws-s3-bucket/commit/69f0f4ebfb93969ec8950e92fd32215d718f63c9))
Copy file name to clipboardExpand all lines: README.md
+20-5Lines changed: 20 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,6 +16,8 @@ These features of S3 bucket configurations are supported:
16
16
- Cross-Region Replication (CRR)
17
17
- ELB log delivery bucket policy
18
18
- ALB/NLB log delivery bucket policy
19
+
- Account-level Public Access Block
20
+
- S3 Directory Bucket
19
21
20
22
## Usage
21
23
@@ -63,7 +65,6 @@ module "s3_bucket_for_logs" {
63
65
source = "terraform-aws-modules/s3-bucket/aws"
64
66
65
67
bucket = "my-s3-bucket-for-logs"
66
-
acl = "log-delivery-write"
67
68
68
69
# Allow deletion of non-empty bucket
69
70
force_destroy = true
@@ -117,22 +118,26 @@ Users of Terragrunt can achieve similar results by using modules provided in the
117
118
118
119
-[Complete](https://github.com/terraform-aws-modules/terraform-aws-s3-bucket/tree/master/examples/complete) - Complete S3 bucket with most of supported features enabled
119
120
-[Cross-Region Replication](https://github.com/terraform-aws-modules/terraform-aws-s3-bucket/tree/master/examples/s3-replication) - S3 bucket with Cross-Region Replication (CRR) enabled
120
-
-[S3 Bucket Notifications](https://github.com/terraform-aws-modules/terraform-aws-s3-bucket/tree/master/examples/notification) - S3 bucket notifications to Lambda functions, SQS queues, and SNS topics.
|[aws_caller_identity.current](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/caller_identity)| data source |
165
171
|[aws_canonical_user_id.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/canonical_user_id)| data source |
166
172
|[aws_iam_policy_document.access_log_delivery](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
167
173
|[aws_iam_policy_document.combined](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
168
174
|[aws_iam_policy_document.deny_incorrect_encryption_headers](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
169
175
|[aws_iam_policy_document.deny_incorrect_kms_key_sse](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
170
176
|[aws_iam_policy_document.deny_insecure_transport](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
177
+
|[aws_iam_policy_document.deny_ssec_encrypted_object_uploads](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
171
178
|[aws_iam_policy_document.deny_unencrypted_object_uploads](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
172
179
|[aws_iam_policy_document.elb_log_delivery](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
173
180
|[aws_iam_policy_document.inventory_and_analytics_destination_policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document)| data source |
@@ -195,20 +202,23 @@ No modules.
195
202
| <aname="input_attach_deny_incorrect_encryption_headers"></a> [attach\_deny\_incorrect\_encryption\_headers](#input\_attach\_deny\_incorrect\_encryption\_headers)| Controls if S3 bucket should deny incorrect encryption headers policy attached. |`bool`|`false`| no |
196
203
| <aname="input_attach_deny_incorrect_kms_key_sse"></a> [attach\_deny\_incorrect\_kms\_key\_sse](#input\_attach\_deny\_incorrect\_kms\_key\_sse)| Controls if S3 bucket policy should deny usage of incorrect KMS key SSE. |`bool`|`false`| no |
197
204
| <aname="input_attach_deny_insecure_transport_policy"></a> [attach\_deny\_insecure\_transport\_policy](#input\_attach\_deny\_insecure\_transport\_policy)| Controls if S3 bucket should have deny non-SSL transport policy attached |`bool`|`false`| no |
205
+
| <aname="input_attach_deny_ssec_encrypted_object_uploads"></a> [attach\_deny\_ssec\_encrypted\_object\_uploads](#input\_attach\_deny\_ssec\_encrypted\_object\_uploads)| Controls if S3 bucket should deny SSEC encrypted object uploads. |`bool`|`false`| no |
198
206
| <aname="input_attach_deny_unencrypted_object_uploads"></a> [attach\_deny\_unencrypted\_object\_uploads](#input\_attach\_deny\_unencrypted\_object\_uploads)| Controls if S3 bucket should deny unencrypted object uploads policy attached. |`bool`|`false`| no |
199
207
| <aname="input_attach_elb_log_delivery_policy"></a> [attach\_elb\_log\_delivery\_policy](#input\_attach\_elb\_log\_delivery\_policy)| Controls if S3 bucket should have ELB log delivery policy attached |`bool`|`false`| no |
200
208
| <aname="input_attach_inventory_destination_policy"></a> [attach\_inventory\_destination\_policy](#input\_attach\_inventory\_destination\_policy)| Controls if S3 bucket should have bucket inventory destination policy attached. |`bool`|`false`| no |
201
209
| <aname="input_attach_lb_log_delivery_policy"></a> [attach\_lb\_log\_delivery\_policy](#input\_attach\_lb\_log\_delivery\_policy)| Controls if S3 bucket should have ALB/NLB log delivery policy attached |`bool`|`false`| no |
202
210
| <aname="input_attach_policy"></a> [attach\_policy](#input\_attach\_policy)| Controls if S3 bucket should have bucket policy attached (set to `true` to use value of `policy` as bucket policy) |`bool`|`false`| no |
203
211
| <aname="input_attach_public_policy"></a> [attach\_public\_policy](#input\_attach\_public\_policy)| Controls if a user defined public bucket policy will be attached (set to `false` to allow upstream to apply defaults to the bucket) |`bool`|`true`| no |
204
212
| <aname="input_attach_require_latest_tls_policy"></a> [attach\_require\_latest\_tls\_policy](#input\_attach\_require\_latest\_tls\_policy)| Controls if S3 bucket should require the latest version of TLS |`bool`|`false`| no |
213
+
| <aname="input_availability_zone_id"></a> [availability\_zone\_id](#input\_availability\_zone\_id)| Availability Zone ID or Local Zone ID |`string`|`null`| no |
205
214
| <aname="input_block_public_acls"></a> [block\_public\_acls](#input\_block\_public\_acls)| Whether Amazon S3 should block public ACLs for this bucket. |`bool`|`true`| no |
206
215
| <aname="input_block_public_policy"></a> [block\_public\_policy](#input\_block\_public\_policy)| Whether Amazon S3 should block public bucket policies for this bucket. |`bool`|`true`| no |
207
216
| <aname="input_bucket"></a> [bucket](#input\_bucket)| (Optional, Forces new resource) The name of the bucket. If omitted, Terraform will assign a random, unique name. |`string`|`null`| no |
208
217
| <aname="input_bucket_prefix"></a> [bucket\_prefix](#input\_bucket\_prefix)| (Optional, Forces new resource) Creates a unique bucket name beginning with the specified prefix. Conflicts with bucket. |`string`|`null`| no |
209
218
| <aname="input_control_object_ownership"></a> [control\_object\_ownership](#input\_control\_object\_ownership)| Whether to manage S3 Bucket Ownership Controls on this bucket. |`bool`|`false`| no |
210
219
| <aname="input_cors_rule"></a> [cors\_rule](#input\_cors\_rule)| List of maps containing rules for Cross-Origin Resource Sharing. |`any`|`[]`| no |
211
220
| <aname="input_create_bucket"></a> [create\_bucket](#input\_create\_bucket)| Controls if S3 bucket should be created |`bool`|`true`| no |
221
+
| <aname="input_data_redundancy"></a> [data\_redundancy](#input\_data\_redundancy)| Data redundancy. Valid values: `SingleAvailabilityZone`|`string`|`null`| no |
212
222
| <aname="input_expected_bucket_owner"></a> [expected\_bucket\_owner](#input\_expected\_bucket\_owner)| The account ID of the expected bucket owner |`string`|`null`| no |
213
223
| <aname="input_force_destroy"></a> [force\_destroy](#input\_force\_destroy)| (Optional, Default:false ) A boolean that indicates all objects should be deleted from the bucket so that the bucket can be destroyed without error. These objects are not recoverable. |`bool`|`false`| no |
214
224
| <aname="input_grant"></a> [grant](#input\_grant)| An ACL policy grant. Conflicts with `acl`|`any`|`[]`| no |
@@ -218,8 +228,10 @@ No modules.
218
228
| <aname="input_inventory_self_source_destination"></a> [inventory\_self\_source\_destination](#input\_inventory\_self\_source\_destination)| Whether or not the inventory source bucket is also the destination bucket. |`bool`|`false`| no |
219
229
| <aname="input_inventory_source_account_id"></a> [inventory\_source\_account\_id](#input\_inventory\_source\_account\_id)| The inventory source account id. |`string`|`null`| no |
220
230
| <aname="input_inventory_source_bucket_arn"></a> [inventory\_source\_bucket\_arn](#input\_inventory\_source\_bucket\_arn)| The inventory source bucket ARN. |`string`|`null`| no |
231
+
| <aname="input_is_directory_bucket"></a> [is\_directory\_bucket](#input\_is\_directory\_bucket)| If the s3 bucket created is a directory bucket |`bool`|`false`| no |
221
232
| <aname="input_lb_log_delivery_policy_source_organizations"></a> [lb\_log\_delivery\_policy\_source\_organizations](#input\_lb\_log\_delivery\_policy\_source\_organizations)| (Optional) List of AWS Organization IDs should be allowed to deliver ALB/NLB logs to this bucket. |`list(string)`|`[]`| no |
222
233
| <aname="input_lifecycle_rule"></a> [lifecycle\_rule](#input\_lifecycle\_rule)| List of maps containing configuration of object lifecycle management. |`any`|`[]`| no |
234
+
| <aname="input_location_type"></a> [location\_type](#input\_location\_type)| Location type. Valid values: `AvailabilityZone` or `LocalZone`|`string`|`null`| no |
| <aname="input_tags"></a> [tags](#input\_tags)| (Optional) A mapping of tags to assign to the bucket. |`map(string)`|`{}`| no |
236
248
| <aname="input_transition_default_minimum_object_size"></a> [transition\_default\_minimum\_object\_size](#input\_transition\_default\_minimum\_object\_size)| The default minimum object size behavior applied to the lifecycle configuration. Valid values: all\_storage\_classes\_128K (default), varies\_by\_storage\_class |`string`|`null`| no |
249
+
| <aname="input_type"></a> [type](#input\_type)| Bucket type. Valid values: `Directory`|`string`|`"Directory"`| no |
237
250
| <aname="input_versioning"></a> [versioning](#input\_versioning)| Map containing versioning configuration. |`map(string)`|`{}`| no |
238
251
| <aname="input_website"></a> [website](#input\_website)| Map containing static web-site hosting or redirect configuration. |`any`|`{}`| no |
239
252
@@ -251,6 +264,8 @@ No modules.
251
264
| <aname="output_s3_bucket_region"></a> [s3\_bucket\_region](#output\_s3\_bucket\_region)| The AWS region this bucket resides in. |
252
265
| <aname="output_s3_bucket_website_domain"></a> [s3\_bucket\_website\_domain](#output\_s3\_bucket\_website\_domain)| The domain of the website endpoint, if the bucket is configured with a website. If not, this will be an empty string. This is used to create Route 53 alias records. |
253
266
| <aname="output_s3_bucket_website_endpoint"></a> [s3\_bucket\_website\_endpoint](#output\_s3\_bucket\_website\_endpoint)| The website endpoint, if the bucket is configured with a website. If not, this will be an empty string. |
267
+
| <aname="output_s3_directory_bucket_arn"></a> [s3\_directory\_bucket\_arn](#output\_s3\_directory\_bucket\_arn)| ARN of the directory bucket. |
268
+
| <aname="output_s3_directory_bucket_name"></a> [s3\_directory\_bucket\_name](#output\_s3\_directory\_bucket\_name)| Name of the directory bucket. |
0 commit comments