Thinking of moving a static site to S3 + CloudFront + AWS Certificate Manager with the purpose of enabling HTTPS for the site. Seems like CloudFront does not support index document even if you've enabled it on S3 ( https://tiffanybbrown.com/2016/01/aws-certificate-manager-s3... ). You can't have URL such as https://example.com/about/ . Instead need to specifically use URL https://example.com/about/index.html . Will l…
I'm using index document paths on S3 + CloudFront right now, it's definitely possible. Unfortunately, I don't remember exactly what I did to make it work. Some more Googling might give you the answer. Edit: the setting is called "Default Root Object" when setting up a CloudFront distribution with an S3 origin.
Open source template for building static web sites with Prismic.io and AWS S3
11–20 of 23 posts
Re: Open source template for building static web sites with Prismic.io and AWS S3
#12See: https://medium.com/teletext-io-blog/empower-your-static-gene...
Re: Open source template for building static web sites with Prismic.io and AWS S3
#13Earlier quoted context omitted.
I'm using index document paths on S3 + CloudFront right now, it's definitely possible. Unfortunately, I don't remember exactly what I did to make it work. Some more Googling might give you the answer. Edit: the setting is called "Default Root Object" when setting up a CloudFront distribution with an S3 origin.
Does that setting apply to any subdirectory? The article linked in a comment above states otherwise.
No, unfortunately it doesn't.
One workaround that I use is to upload files without an extension and explicitly set their content type as `text/html` in S3. So a request to `/about` just serves a file in your S3 bucket called `about`. This works with both CloudFront and S3.
I wrote about a few more details of the process here: https://brandur.org/fragments/aws-static-hosting-workaround
Re: Open source template for building static web sites with Prismic.io and AWS S3
#14Re: Open source template for building static web sites with Prismic.io and AWS S3
#15Here is a very quickstart tutorial to test prismic.io https://prismic.io/quickstart Don't hesitate to ask questions!
disclaimer: no affiliation with Prismic.io
...and Play is really quite awesome, thanks Guillaume and Sadache! Thanks for the open bar you guys sponsored after Scala.io Paris conference as well ;-)
Re: Open source template for building static web sites with Prismic.io and AWS S3
#16Thinking of moving a static site to S3 + CloudFront + AWS Certificate Manager with the purpose of enabling HTTPS for the site. Seems like CloudFront does not support index document even if you've enabled it on S3 ( https://tiffanybbrown.com/2016/01/aws-certificate-manager-s3... ). You can't have URL such as https://example.com/about/ . Instead need to specifically use URL https://example.com/about/index.html . Will l…
Re: Open source template for building static web sites with Prismic.io and AWS S3
#17What we do is create a static site using Jekyll (or any other SSG) and then add teletext.io on top for content management. Then host it in S3 or GitHub pages. See: https://medium.com/teletext-io-blog/empower-your-static-gene...
Re: Open source template for building static web sites with Prismic.io and AWS S3
#18Thinking of moving a static site to S3 + CloudFront + AWS Certificate Manager with the purpose of enabling HTTPS for the site. Seems like CloudFront does not support index document even if you've enabled it on S3 ( https://tiffanybbrown.com/2016/01/aws-certificate-manager-s3... ). You can't have URL such as https://example.com/about/ . Instead need to specifically use URL https://example.com/about/index.html . Will l…
Re: Open source template for building static web sites with Prismic.io and AWS S3
#19Thinking of moving a static site to S3 + CloudFront + AWS Certificate Manager with the purpose of enabling HTTPS for the site. Seems like CloudFront does not support index document even if you've enabled it on S3 ( https://tiffanybbrown.com/2016/01/aws-certificate-manager-s3... ). You can't have URL such as https://example.com/about/ . Instead need to specifically use URL https://example.com/about/index.html . Will l…
That is not true. This site is built with Hugo hosted on S3, running behind CloudFront and uses the AWS Certificate Manager: https://owenconti.com/about/
Make sure the S3 bucket is set to Static Website Hosting mode, and make sure your Index and Error documents are set appropriately. Then make sure your CloudFront distribution is pointed at the Website's endpoint and NOT the normal S3 endpoint.
Re: Open source template for building static web sites with Prismic.io and AWS S3
#20Earlier quoted context omitted.
That is not true. This site is built with Hugo hosted on S3, running behind CloudFront and uses the AWS Certificate Manager: https://owenconti.com/about/
Replying to myself as a follow up: Make sure the S3 bucket is set to Static Website Hosting mode, and make sure your Index and Error documents are set appropriately. Then make sure your CloudFront distribution is pointed at the Website's endpoint and NOT the normal S3 endpoint.