humanmade / tachyon

Faster than light image resizing service that runs on AWS. Super simple to set up, highly available and very performant.

Home Page:https://engineering.hmn.md/projects/tachyon/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

New TTL Issues with Cloudformation

karikas opened this issue · comments

Using the latest cloudformation-template.json the creation process would cause an error with a message like this:
MinTTL, MaxTTL and DefaultTTL should follow order MinTTL less than or equal to DefaultTTL less than or equal to MaxTTL (Service: AmazonCloudFront; Status Code: 400; Error Code: InvalidTTLOrder; Request ID: xxx)

It looks like fairly recently the config was updated to address this, but still won't successfully build. Adjusting the values to be further apart from each other still triggered this error. To complete the build I had to remove all TTL values from the .json file and rely on the defaults, including the DefaultTTL under CloudFrontDistribution -> DistributionConfig -> CacheBehaviors. Thought you should know!

I ran into this as well and found that it has to do with the large TTLs in the configuration. I set mine to 31536000 and it worked fine.

Fixed in PR #69.