Setting a DAM as your main asset source in CloudCannon allows you to use DAM URLs which start with "/", instead of being fully qualified. A fully qualified URL is a complete Internet address and must include a hostname and top-level domain.
By default, all the URLs for assets on your DAM need to be fully qualified in order to preview them on CloudCannon. Similarly, CloudCannon will always save fully qualified URLs in your code when you upload an asset to a DAM through the CMS. This behaviour can be turned off by setting a DAM as your main asset source.
Main source configuration#
The main asset source for your site can be the site files or a DAM linked to the site. By default, the main source is your site files.
If you choose a DAM to be your main asset source, you will not be able to browse assets from, or upload to, your site files in CloudCannon.
- In your site’s settings, navigate to Files/Assets
- Locate your DAM (or Site Files) from the list, and click the three dots in the top right corner
- From the context menu, click Set Main Source
- Click the Confirm button
When changing your main asset source, you might need to rewrite existing URLs on the site, to avoid broken previews in CloudCannon.