Skip to content

HasanMansoor4/multidomain-spa-with-cdk-and-cloudfront

 
 

Repository files navigation

Building multi-subdomain applications with AWS CDK and CloudFront

This template will deploy a sample html application that listens to incoming requests from any subdomain on the domain specified when the stack is created.

Detailed instructions here: https://aws.amazon.com/blogs/infrastructure-and-automation/deploy-spa-with-personalized-subdomains-using-aws-cdk/

Infrastructure created:

  • S3 bucket
  • Domain TLS certificate
  • Route 53 DNS entry
  • CloudFront distribution

Prerequisites

How to deploy this Template

Run

cdk bootstrap
cdk deploy -c primaryDomain={your-domain.name}  

Cleanup

You will need to manually delete the index.html in the S3 bucket then remove the stack with:

Run

cdk destroy

Security

See CONTRIBUTING for more information.

License

This library is licensed under the MIT-0 License. See the LICENSE file.

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 78.0%
  • JavaScript 11.2%
  • HTML 10.8%