From 7456546f11f7befec5005537e83cbcc57e6d58fa Mon Sep 17 00:00:00 2001 From: Mark Croxton Date: Wed, 3 May 2023 18:27:06 +0100 Subject: [PATCH] Update docs and prep for release. --- CHANGELOG.md | 4 ++++ README.md | 52 +++++++++++++++++++++++++++++++++++++++++++++------ composer.json | 2 +- 3 files changed, 51 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6810341..e09818b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +## 2.1.3 - 2023.05.03 +### Added +- Support for Servd's Asset Platform v3. + ## 2.1.2 - 2023.02.23 ### Fixed - Fixed image previews in SEOmatic link cards. diff --git a/README.md b/README.md index 59ff3be..247ad0d 100644 --- a/README.md +++ b/README.md @@ -176,16 +176,38 @@ There are several ways to use Imgixer with [Servd.host](https://servd.host) asse With either option, you will first need to install [Servd Assets and Helpers](https://github.com/servdhost/craft-asset-storage). ### 1. Using an Imgix Web Folder source - -* Set up a Web Folder source in Imgix with the base URL set to Servd's CDN URL for your project, e.g. `https://cdn2.assets-servd.host/my-served-project-slug`. + +#### Servd Assets Platform v2 +* Set up a `Web Folder` source in Imgix with the base URL set to Servd's CDN URL for your project, e.g. `https://cdn2.assets-servd.host/my-served-project-slug`. * Recommended: tick the option to use secure URLs and make a note of the key. -* Create a source in `imgixer.php` config, adding `servd` as the asset transform provider: +* Create a new source in `imgixer.php` config: ```php 'my-servd-web-folder' => array( - 'provider' => 'servd', + 'provider' => 'imgix', + 'endpoint' => 'my-domain.imgix.net', + 'privateKey' => '12345', + 'signed' => true, + 'defaultParams' => array( + 'auto' => 'compress,format', + 'fit' => 'crop', + 'q' => '80' + ) +), +``` + +#### Servd Assets Platform v3 +* Set up a `Web Folder` source in Imgix with the base URL set to Servd's *file* domain for your project e.g. `https://my-served-project-slug.files.svdcdn.com` (if you have set up a custom file domain, use that instead). + +* Recommended: tick the option to use secure URLs and make a note of the key. + +* Create a new source in `imgixer.php` config: + +```php +'my-servd-web-folder' => array( + 'provider' => 'imgix', 'endpoint' => 'my-domain.imgix.net', 'privateKey' => '12345', 'signed' => true, @@ -199,13 +221,31 @@ With either option, you will first need to install [Servd Assets and Helpers](ht ### 2. Use Servd's own image transformation service -Servd provides its own image transformation service (https://optimise2.assets-servd.host) that supports a subset of Imgix's Rendering API and covers the majority of use cases. If you are hosting with Servd it may be all you need. +Servd's Asset Platform provides an image transformation service that supports a subset of Imgix's Rendering API and covers the majority of use cases. If you are hosting with Servd it may be all you need. + +#### Servd Assets Platform v2 + +Create a source in `imgixer.php` config, adding `servd` as the asset provider. Do not set an endpoint: + +```php +'my-servd-assets' => array( + 'provider' => 'servd', + 'defaultParams' => array( + 'auto' => 'format', + 'fit' => 'crop', + 'q' => '80' + ) +), +``` + +#### Servd Assets Platform v3 -Create a source in `imgixer.php` config, adding `servd` as the asset provider. Do not set a domain: +Create a source in `imgixer.php` config, adding `servd` as the asset provider. Add Servd's *transform* domain as the endpoint for the source (if you have set up a custom transform domain, use that instead). ```php 'my-servd-assets' => array( 'provider' => 'servd', + 'endpoint' => , 'https://my-served-project-slug.transforms.svdcdn.com' 'defaultParams' => array( 'auto' => 'format', 'fit' => 'crop', diff --git a/composer.json b/composer.json index 596d04a..b1f01e7 100644 --- a/composer.json +++ b/composer.json @@ -2,7 +2,7 @@ "name": "croxton/imgixer", "description": "Generate Imgix URLs.", "type": "craft-plugin", - "version": "2.1.2", + "version": "2.1.3", "keywords": [ "craft", "cms",