Terraform module | Static site with S3 and Cloudfront

file structure
  • variable “environment” {} : This variable stands for the Env of resource and is appended with s3 bucket name.
  • variable “name” {} : This is name of the resources
  • variable “acm” {} : arn of AWS Certificate manager is provided here. Make sure this certificate is in “issued” status
  • variable “domain” {} : This will be the custom domain name of our distribution.
  • variable “root_object” {} : usually index.html



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Anil Augustine Chalissery

Anil Augustine Chalissery

DevOps Engineer | AWS Enthusiast | Analyse -> Solve -> Automate