You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First off, arc_ecto's support for signed S3 urls is fantastic. The library in general makes it easy to version & apply transforms to your assets. Kudos!
However, for the library to support signed cloudfront URL's, I had to do a little regex to remove the versioning[0]:
# In reality, I take the version number and pass it as an additional parameter after signing
String.replace(App.Record.url({song.record, song}), ~r/(\?v=).*$/, "")
Because otherwise running the Cloudfront signing script[1] would now have two ?'s in the URL, thereby breaking the URL and having Cloudfront cache a 403 response for that asset. It would be kewl to add support for passing in your Cloudfront key pair. Would this be an issue for ex_aws?
First off, arc_ecto's support for signed S3 urls is fantastic. The library in general makes it easy to version & apply transforms to your assets. Kudos!
However, for the library to support signed cloudfront URL's, I had to do a little regex to remove the versioning[0]:
Because otherwise running the Cloudfront signing script[1] would now have two ?'s in the URL, thereby breaking the URL and having Cloudfront cache a 403 response for that asset. It would be kewl to add support for passing in your Cloudfront key pair. Would this be an issue for ex_aws?
[0] Thanks to #31 for the idea
[1] This is what I'm using https://github.com/Frameio/cloudfront-signer
The text was updated successfully, but these errors were encountered: