https://www.techtarget.com/searchaws/tip/Setting-up-a-CloudFront-distribution-on-AWS-S3
AWS CloudFront is a content distribution service used to speed up the distribution of static or dynamic content, such as media (images or video) files, HTML, Java script, CSS files and others. Its simple user interface can help admins set up CloudFront distributions. But the process isn't just point and click. Here's a look at what CloudFront can do and how to deploy it.
In CloudFront, each piece of content is organized into distributions that have unique URLs and are accessed from the Web. The service distributes this content from edge locations; AWS currently has 52 global edge locations for content caching.
AWS CloudFront supports two types of distributions: streaming and download. When a user requests static content with a CloudFront URL, the service finds the nearest edge location based on the request IP and caches the content in that location. All future requests from the same location will have reduced latency.
CloudFront works with AWS Services, including Simple Storage Service (S3), Elastic Compute Cloud (EC2), elastic load balancing (ELB) and Route 53. Main features of CloudFront include:
To set up a CloudFront Web distribution from an S3 bucket, you'll need an S3 bucket with an object that's publicly accessible (Figure 1).
Then follow these steps:
1. Go to CloudFront and create a Web distribution.
2. Select the bucket name in Origin Domain name and select "No" for Restrict Bucket Access.This will restrict access object only from CloudFront so no one can access it from S3 (Figure 2).
3. Configure the caching settings with values such as:
4. Next, setup the Distribution settings.
Once you create distribution, you'll have a CloudFront URL, such as: "http://d3ptzllcr53x1i.CloudFront.net". Then access the object using that URL.
About the author:
Ofir Nachmani is a business technology advisor, blogger and lecturer. Ofir's extensive experience in the world of business technology has made his critically acclaimed blog, IamOnDemand.com, the go-to guide for modern technology startups and developers in the world of cloud computing. Today he advises organizations, leading them through new IT market modifications, while building and executing a modern go-to-market strategy.
30 Jan 2015