Tachyon Faster than light image resizing service that runs on AWS. Super simple to set up, highly available and very performant. |
|
A Human Made project. Maintained by @joehoyle. |
|
Tachyon is built with some strong opinions and assumptions:
- Runs on AWS (using CloudFront, Lambda and API Gateway.)
- Expects original image files to be stored on Amazon S3.
- Only supports simple image resizing, not a full image manipulation service.
Tachyon works best with WordPress, coupled with S3 Uploads and the Tachyon Plugin.
Tachyon is simple to install, just use the cloudformation-template.json
in this repository to create the whole stack using AWS CloudFormation. It will ask you for a few details along the way.
You'll need to upload the latest release to Amazon S3 and put the location in the to the CloudFormation stack configuration.
Tachyon provides a simple HTTP interface in the form of:
https://{tachyon-domain}/my/image/path/on/s3.png?w=100&h=80
It's really that simple!
URL Arg | Type | Description |
---|---|---|
w |
Number | Max width of the image. |
h |
Number | Max height of the image. |
resize |
String, "w,h" | Resize and crop an image to exact width,height pixel dimensions. |
quality |
Number, 0-100 | Image quality. |
crop |
String, "x,y,w,h" | Crop an image by percentages x-offset,y-offset,width,height (x,y,w,h). Percentages are used so that you don’t need to recalculate the cropping when transforming the image in other ways such as resizing it. crop=160px,160px,788px,788px takes a 788 by 788 square starting at 160 by 160. |
webp |
Boolean, 1 | Force WebP format. |
lb |
String, "w,h" | Add letterboxing effect to images, by scaling them to width, height while maintaining the aspect ratio and filling the rest with black or background . |
background |
String | Add background color via name (red) or hex value (%23ff0000). Don't forget to escape # as %23 . |
For more details checkout the docs.
Created by Human Made for high volume and large-scale sites, such as Happytables. We run Tachyon on sites with millions of monthly page views, and thousands of sites.
Written and maintained by Joe Hoyle.
Tachyon is inspired by Photon by Automattic. As Tachyon is not an all-purpose image resizer, rather it uses a media library in Amazon S3, it has a different use case to Photon.
Tachyon uses the Sharp (Used under the license Apache License 2.0) Node.js library for the resizing operations, which in turn uses the great libvips library.
Interested in joining in on the fun? Join us, and become human!