Amazon Cloud Free CDN Opening Tutorial

888u

Last update at :2024-02-26,Edit by888u

Amazon CloudFront, is a fast content delivery network (CDN) service that securely distributes data, video, applications, and APIs to customers around the world with low latency and high transfer speeds. For example, we can use it to accelerate websites and S3 object storage. By default, each CloudFront account has 1TB of data traffic per month. Moreover, the CloudFront network has more than 225 nodes (PoP) connected by fully redundant parallel 100GbE fiber, providing ultra-low latency performance and high availability to end users. When serving cached or dynamic content, CloudFront automatically maps network conditions and intelligently routes users' traffic.

For example, we often use S3 acceleration for websites or object storage, and of course load balancing and some API calling applications.

Here we can select the created source according to the prompts, such as AWS S3 or enter the domain name. Remember, this domain name is not the domain name that we directly accelerate the CDN, but points to the domain name that resolves to the server IP, which can be regarded as a springboard. We need to resolve this domain name to the current server IP.

Enter the domain name, and it will detect whether HTTP and HTTPS are supported by default.

Then we need to set the cache behavior, including automatic compression of objects, viewer policies, and allowed HTTP methods. Cache request policies are also provided by default.

Here we select nodes based on our project business. The default recommendation is all nodes. If you have WAF security activated, you can also choose to start it by policy. At the same time, if we use HTTPS, you can also choose to associate the certificate.

What needs to be noted here is, how do we bind our own domain name that really needs a CDN?

Fill in the alternate domain name here is the domain name we really need CDN for. But you can’t really add and save it, and an error will be prompted.

To add an alternate domain name (CNAME) to a CloudFront distribution, you must attach a trusted certificate that validates your authorization to use the domain name. For more details, see: https://docs.aws.amazon.com /AmazonCloudFront/latest/DeveloperGuide/CNAMEs.html#alternate-domain-names-requirements

I need to verify domain ownership in a custom SSL certificate.

If the certificate is successfully verified, we can add the domain name. According to the prompts, we add CNAME resolution to verify the ownership of the current domain name, and wait until the verification is completed before continuing.

You can only add a domain name after waiting for the SSL certification to pass, otherwise it will not pass.

If we need to enable a custom CDN, we need to add CNAME resolution to the assigned domain name. Corresponding to the previous source domain name, point to the IP of the source server.

Of course this is not enough. If we need to parse to the website, we also need to configure it on the server side.

Cloudfront will request your server through port 443 and port 80, that is, https and http protocols. You must configure the CDN application domain name and source domain name mentioned above on your server. We need to add resolution to the domain name of the NGINX configuration site.

server { listen 80; server_name 1.test.com 2.test.com; … }

Something like this.

In this way, our website can be accelerated through Amazon Cloud's CDN, which is generally used by foreign trade websites. For Amazon Cloud CDN service, 1TB of monthly traffic is provided free of charge, and additional charges will be required.

This article is reproduced from: https://www.laozuo.org/25738.html

Recommended site searches: foreign servers, American vps hosts, website virtual host space, filing information, Korean cheap servers, ip proxy, mainland China proxy ip, domain name query, foreign space service providers, vps dynamic ip server,

Amazon Cloud Free CDN Opening Tutorial

All copyrights belong to 888u unless special state
取消
微信二维码
微信二维码
支付宝二维码