Skip to content

Commit

Permalink
Merge pull request #17526 from pradeepbhadani/fix/s3_bucket_policy_doc
Browse files Browse the repository at this point in the history
docs/contributing: Update invalid S3 bucket name and add note for bucket policy size.
  • Loading branch information
breathingdust authored Feb 11, 2021
2 parents b41d553 + 0c68aa1 commit 23a0e73
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions website/docs/r/s3_bucket_policy.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Attaches a policy to an S3 bucket resource.

```hcl
resource "aws_s3_bucket" "b" {
bucket = "my_tf_test_bucket"
bucket = "my-tf-test-bucket"
}
resource "aws_s3_bucket_policy" "b" {
Expand All @@ -32,7 +32,7 @@ resource "aws_s3_bucket_policy" "b" {
"Effect": "Deny",
"Principal": "*",
"Action": "s3:*",
"Resource": "arn:aws:s3:::my_tf_test_bucket/*",
"Resource": "arn:aws:s3:::my-tf-test-bucket/*",
"Condition": {
"IpAddress": {"aws:SourceIp": "8.8.8.8/32"}
}
Expand All @@ -48,7 +48,8 @@ POLICY
The following arguments are supported:

* `bucket` - (Required) The name of the bucket to which to apply the policy.
* `policy` - (Required) The text of the policy. For more information about building AWS IAM policy documents with Terraform, see the [AWS IAM Policy Document Guide](https://learn.hashicorp.com/terraform/aws/iam-policy).
* `policy` - (Required) The text of the policy. For more information about building AWS IAM policy documents with Terraform, see the [AWS IAM Policy Document Guide](https://learn.hashicorp.com/terraform/aws/iam-policy). Note: Bucket policies are limited to 20 KB in size.


## Import

Expand Down

0 comments on commit 23a0e73

Please sign in to comment.