To implement ImageEngine’s image optimization for Sitecore, you will first need to sign up for an ImageEngine account, if you do not already have one. During the signup process, you’ll be asked for the website domain where you intend to use ImageEngine and origin URL for the majority of the images. For more information about signing up, please refer to this article: Getting Started: Signup.
Once signed up, you will be issued a unique delivery address following this pattern: “aabbcc.cdn.imgeng.in.” Custom delivery addresses may also be made after the initial signup process is complete. For more information, see our article here: https://imageengine.io/docs/implementation/domain-name.
Take note of your delivery address, as we will be needing it in the next step.
Add ImageEngine references to Sitecore
Sitecore's CDN properties are defined in the Sitecore.config file. Modifying these settings will allow you to pass images to ImageEngine instead of serving from your current origin:
<setting name="Media.MediaLinkServerUrl" value="aabbcc.cdn.imgeng.in."/>
<setting name="Media.MediaLinkPrefix" value="-/media/images" />
<setting name="Media.AlwaysIncludeServerUrl" value="true" />
<setting name="MediaResponse.Cacheability" value="public" />
Descriptions of the settings to be modified:
is the ImageEngine Delivery Address that you obtained when signing up or manually created later.
is the media library link URL. With ImageEngine we need to specify the directory containing your image content. If you require ImageEngine to deliver non-image content, we can either provide you with a secondary domain or we can make a modification to our edge caching rules to enable mixed content.
tells Sitecore to always include the server URL in the media requests
allows the cache settings of any item to be publicly available. This enables us to access cache-control and other headers.
Please sign in to leave a comment.