Deploy an Amazon CloudFront distribution for a web application with static and dynamic content
Leverage Amazon CloudFront as Content Delivery Network for a web application with static (Amazon S3) and dynamic content (REST API)

- The static content origin is the web page hosted in an Amazon S3 bucket. The S3 bucket is private and only accessible by the Amazon CloudFront distribution using Origin Access Control (OAC)
- The dynamic content origin is a backend application that exposes a REST API.
- Create an AWS account if you do not already have one and log in. The IAM user that you use must have sufficient permissions to make necessary AWS service calls and manage AWS resources.
- AWS CLI installed and configured
- Node and NPM installed
- AWS Cloud Development Kit (AWS CDK) installed
- Create a new directory, navigate to that directory in a terminal and clone the GitHub repository:
- From the command line, use npm to install the development dependencies:
- To deploy from the command line use the following:
Any opinions in this post are those of the individual author and may not reflect the opinions of AWS.