Completing CloudEDGE CDN Configuration

Complete CDN Configuration

After you fulfill the configuration pre-requisites, complete the final steps for configuring CloudEDGE CDN (also known as Webscale CDN).

The final steps consist of the following tasks.

If you decide to roll back Webscale CDN, doing so is a simple process.

Enable Webscale CDN

You can enable Webscale CDN through the CDN page for the application. The CDN delivery options determine how Webscale will use CDN.

After you select Webscale CDN delivery, the following changes occur.

  • All traffic for the application first passes through the CDN provider
  • When using CloudFront, the application has a Cloudfront distribution
  • Cloudfront’s origin will become origin-<application ID>, which resolves to Webscale proxy addresses
  • All requests will reflect the application alias and not the cloudmaestro domains

By default, CDN is disabled. Without CDN, PageSpeed is disabled and the CDN provider is unavailable.

The other CDN delivery method is to have PageSpeed rewrite to CDN. With this legacy option, Pagespeed rewrites to CDN and uses the cloudmaestro domain to deliver content to customers.

To enable Webscale CDN

  1. Click the three vertical dots menu icon on the upper-right corner of the application box and select Edit.

    Select edit application


    On your application page, click the Actions menu icon and select Edit.

    Select edit application
  2. On the sidebar menu, click CDN.

    The CDN page displays with the default delivery option of Without CDN selected.

    CDN page
  3. In the Delivery drop-down menu, select Webscale CDN. The Provider drop-down menu displays. It lists all of the providers enabled for Webscale CDN.

  4. Select the Amazon EC2 provider to use with Webscale CDN for this application.

  5. Click Apply to enable Webscale CDN.

    CDN page

Bypass the CloudFront admin domain

If you need to bypass the admin domain from CloudFront to prevent your requests from timing out, you can complete the bypass process after enabling Webscale CDN.

Doing so points all admin traffic to origin-<application ID>, which is your Webscale hostname.

There are different bypass procedures for new and existing customers.

To bypass the CloudFront admin domain for new customers

  1. While working on fulfilling configuration pre-requisites, create an admin sub-domain. For more information, see Create an admin subdomain in CDN Configuration Pre-requisites.
  2. Enable Webscale CDN.
  3. Through your application, add an alias for the admin sub-domain. For more information about adding an alias, see Application aliases.
  4. Point the admin sub-domain to origin-<application ID> on the DNS.

To bypass the CloudFront admin domain for existing customers

  1. While fulfilling configuration pre-requisites, create an admin sub-domain.
  2. Enable Webscale CDN.
  3. After origin-<application ID> resolves to your proxy IP address, point your admin sub-domain to it.
  4. Through your application, add an alias for the admin sub-domain.

Set up caching policies

By default, Webscale CDN does not cache pages and resources. After enabling Webscale CDN, create two CDN controls to define basic caching policies. Doing so completes Webscale CDN configuration.

On the CDN page, add two CDN controls to complete Webscale CDN configuration. One CDN control configures caching for media assets. The other defines how Webscale CDN caches static assets.

For information on Webscale CDN caching, see Configuring CDN Caching Policies.

Add CDN controls for media and static assets

Specify paths for caching media and static assets. When enabling Webscale CDN, create CDN controls with the following paths. Each path points to the asset location. Use wild cards when specifying paths. Save and apply the CDN controls after specifying the following settings.

  • Use /media/* as the path for caching media assets.
  • Use /static/* as the path for static assets.

Enter 86400 as the default TTL for both CDN controls. TTL, an acronym for Time to Live, specifies how long (in seconds) an asset will be cached before it needs to be fetched again.

Specify CDN Control settings

Validate the configuration

After you complete the final steps, perform a validation check to ensure that Webscale CDN delivers all assets. Using developer tools, examine a static asset. Check the asset’s X-Cache header to verify that Hit from Cloudfront displays for it.

After you set up caching policies, Webscale CDN does not immediately start caching. The request with the static asset might initially be a miss from CloudFront. After you re-load the page, it should be a hit.

Rolling back the configuration

To roll back Webscale CDN, delete all CDN Controls on the CDN page. Doing so reinstates the default caching policy for Webscale CDN to not cache anything. Traffic still passes through Webscale CDN.

Further reading

Last modified November 10, 2020