provider/aws: Improvde the Cloudfront documentation when using s3 origins (#10087)

This commit is contained in:
Ninir 2016-12-08 12:01:18 +01:00 committed by Paul Stack
parent b03af1416e
commit 7f69f37318
1 changed files with 10 additions and 1 deletions

View File

@ -25,9 +25,18 @@ want to wait, you need to use the `retain_on_delete` flag.
The following example below creates a CloudFront distribution with an S3 origin.
```
resource "aws_s3_bucket" "b" {
bucket = "mybucket"
acl = "private"
tags {
Name = "My bucket"
}
}
resource "aws_cloudfront_distribution" "s3_distribution" {
origin {
domain_name = "mybucket.s3.amazonaws.com"
domain_name = "${aws_s3_bucket.b.bucket}.s3.amazonaws.com"
origin_id = "myS3Origin"
s3_origin_config {