Skip to content

Latest commit

 

History

History

cloudfront-cdn

CloudFront CDN with custom domain

Terraform

Live example | API Docs

Tested with custom subdomain.

Stack

  • CloudFront
  • S3
  • Amazon Certificate Manager
    • Custom SSL Certificate
  • Route53

Pricing

In most cases, the price will be near to zero.

The pricing is based on the number of requests and the amount of data transferred (pay-per-use). See AWS CloudFront Pricing, AWS S3 Pricing and AWS Route53 Pricing.

Note: The price of Route53 Hosted Zone is not included.

How to use

Change the values on terraform.tfvars file to your needs.

# See the changes
terraform plan

# Apply the changes
terraform apply

This example don't consider Remote State. You can use Terraform Remote State to store the state file in a remote location.