Test your website performance for free
Test your website performance

Using a Custom CDN Host

Using a Custom CDN Host

Scrivito serves binary data (such as images or PDF files) through a global content delivery network (CDN), which ensures that the data is made available at high speed, regardless of the user’s location. The domain name of any Scrivito CDN URL is scrvt.com.

If you prefer to use your own domain for content delivery, you can configure it in your Scrivito Dashboard. Open the details page of your CMS, switch to the “Settings” tab, scroll down, and enter the “Danger Zone”.

The “Custom CDN Host” option lets you specify your own domain for binary data delivery. The blobs of your Scrivito tenant must be reachable at the root path of your CDN domain. The Dashboard will check this, and present you with an error if it fails to reach your tenant’s content via the specified host.

You can make your tenant’s content available via your own domain by means of a proxy server, or through a CDN provider, e.g. AWS CloudFront, that uses Scrivito’s CDN as its source.

Using an AWS CloudFront Distribution as the CDN

To use an AWS CloudFront distribution with a custom domain, you will need to provide a suitable certificate via AWS Certificate Manager (ACM).

  1. In your AWS CloudFront console, switch to the “Policy” section and create
    • a cache policy including the Accept header and all query strings in cache keys, and
    • an origin request policy, including the Accept header and all query strings in the origin request settings.
  2. Switch to the distributions and create a new CloudFront distribution.
  3. Set the “Origin Domain Name” to cdn.scrvt.com and the “Origin Path” to / followed by your tenant’s ID. Also, change the “Origin Protocol Policy” to HTTPS Only.
  4. When configuring the default cache behavior, select the cache and origin request policy you created before.
  5. Add your CDN domain name to the “Alternate Domain Names” and select the corresponding “SSL Certificate”.
  6. After creating the CloudFront distribution and waiting for its deployment to complete, configure the DNS for your domain so that it uses the CloudFront domain displayed on the details page of your distribution.

You are now ready to specify your CDN domain as your tenant’s “Custom CDN Host” in your Scrivito Dashboard.