Steps for creating a distribution (overview) - Amazon CloudFront
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Steps for creating a distribution (overview)

The following task list summarizes the process for creating a distribution.

To create a distribution
  1. Create one or more Amazon S3 buckets, or configure HTTP servers as your origin servers. An origin is the location where you store the original version of your content. When CloudFront gets a request for your files, it goes to the origin to get the files that it distributes at edge locations. You can use any combination of Amazon S3 buckets and HTTP servers as your origin servers.

    If you use Amazon S3, the name of your bucket must be all lowercase and cannot contain spaces.

    If you use an Amazon EC2 server or another custom origin, review Using Amazon EC2 (or another custom origin).

    For the current maximum number of origins that you can create for a distribution, or to request a higher quota, see General quotas on distributions.

  2. Upload your content to your origin servers. You make your objects publicly readable, or you can use CloudFront signed URLs to restrict access to your content.

    Important

    You are responsible for ensuring the security of your origin server. You must ensure that CloudFront has permission to access the server and that the security settings safeguard your content.

  3. Create your CloudFront distribution:

    • For more information about using the CloudFront console to create a distribution, see Creating a distribution.

    • For information about creating a distribution using the CloudFront APIs, go to CreateDistribution in the Amazon CloudFront API Reference.

  4. (Optional) If you use the CloudFront console to create your distribution, create more cache behaviors or origins for the distribution. For more information about behaviors and origins, see To update a CloudFront distribution.

  5. Test your distribution. For more information about testing, see Testing a distribution.

  6. Develop your website or application to access your content using the domain name that CloudFront returned after you created your distribution in Step 3. For example, if CloudFront returns d111111abcdef8.cloudfront.net as the domain name for your distribution, the URL for the file image.jpg in an Amazon S3 bucket or in the root directory on an HTTP server is https://d111111abcdef8.cloudfront.net/image.jpg.

    If you specified one or more alternate domain names (CNAMEs) when you created your distribution, you can use your own domain name. In that case, the URL for image.jpg might be https://www.example.com/image.jpg.

    Note the following: