{"id":21106943,"url":"https://github.com/buildo/terraform-aws-website","last_synced_at":"2026-01-02T05:25:34.479Z","repository":{"id":52648020,"uuid":"116248754","full_name":"buildo/terraform-aws-website","owner":"buildo","description":"Terraform module for creating static websites hosted on S3 and served via CloudFront","archived":false,"fork":false,"pushed_at":"2021-04-22T12:28:45.000Z","size":32,"stargazers_count":19,"open_issues_count":2,"forks_count":6,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-01-21T03:41:34.942Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://registry.terraform.io/modules/buildo/website/aws/","language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/buildo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-01-04T10:48:56.000Z","updated_at":"2021-11-10T23:45:52.000Z","dependencies_parsed_at":"2022-08-22T00:41:02.855Z","dependency_job_id":null,"html_url":"https://github.com/buildo/terraform-aws-website","commit_stats":null,"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buildo%2Fterraform-aws-website","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buildo%2Fterraform-aws-website/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buildo%2Fterraform-aws-website/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buildo%2Fterraform-aws-website/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/buildo","download_url":"https://codeload.github.com/buildo/terraform-aws-website/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243551327,"owners_count":20309300,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-20T00:34:36.846Z","updated_at":"2026-01-02T05:25:34.418Z","avatar_url":"https://github.com/buildo.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# website Terraform module\n\nThis is a Terraform module designed to automate the deploy of a static website.\n\nThis modules creates the following resources:\n\n- two S3 buckets, one for the content (`www.example.com`), one for redirecting from the\n  naked domain to www (named `example.com`)\n- two CloudFront distribution, one per bucket, that also redirect from HTTP to HTTPS\n- two Route53 alias records, one per CloudFront distribution\n\n## Usage\n### Prerequisites\nYou have to create a SSL certificate for both domains (www and naked) on AWS.\nThis step can't be automated, due to limitations of the AWS API.\n\nFollow this instructions:\n\n- Access the [Certificate Manager](https://console.aws.amazon.com/acm/) on the AWS console\n- Switch to the `us-east-1` (N. Virginia) region.\n  - 🚨 **This is CRUCIAL, as AWS requires certificates for CloudFront to be issued in this region**\n- Click on \"Request a certificate\"\n- Enter as a primary domain name the domain you want *with www*, for example: `www.buildo.io`\n- Enter the naked domain as an additional domain name, for example `buildo.io`\n\nYou should be in this situation:\n\n![image](https://user-images.githubusercontent.com/691940/34524695-bbb25322-f09c-11e7-9fc1-b20e4629b8db.png)\n\n**NOTE**: ⚠️ the order is important, the `www` domain must come first!\n\n- Follow the steps for verifying the domain\n\n### Using the module\nUsing the module is as simple as:\n\n```hcl\nprovider \"aws\" {\n  region = \"eu-west-1\" // The region for the S3 buckets and the CloudFront distribution\n}\n\nmodule \"website\" {\n  source = \"buildo/website/aws\"\n  domain = \"mysite.com\" // no www here\n\n  # optional: enable health check on www.mysite.com\n  enable_health_check = true\n  health_check_alarm_sns_topics = [\n    \"\u003carn of a topic to notify for health check alarms\u003e\"\n  ]\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuildo%2Fterraform-aws-website","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbuildo%2Fterraform-aws-website","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuildo%2Fterraform-aws-website/lists"}