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
This Terraform module creates a static site setup using Amazon S3 and CloudFront + OAC, with support for features like custom R53 domains, SPA support, and logging.
Features
S3 + Block Public Access
CloudFront + Origin Access Control (OAC)
All bucket access is restricted to CloudFront via OAC
Optional custom domain with ACM certificate
SPA support
Configurable access logging with retention policy
Server-side encryption (AES256 or KMS)
Notes
SPA mode redirects 404 errors to index.html with a 200 status code
The module automatically creates a logging bucket, if not provided
Wildcard certificates (*.example.com) are supported for custom domains
Custom domains use ACM certificates which must be created in us-east-1
For ACM, you must configure and pass the aliased provider: