All threads / Refile :fill does not work for me

Ask A Question


You’re not receiving notifications from this thread.

Refile :fill does not work for me

Wesly Mezarina asked in Gems / Libraries

I have the refile gem connected with aws by following the instruction on their github. For an image i would get something like


which works but when i try to use the :fill that refile provides my images don't display. You can see that i have the fill/400/400 in the url below.


I'm guessing that i have to change the way aws stores the image in this code.

require "refile/backend/s3"

aws = {
  access_key_id: "xyz",
  secret_access_key: "abc",
  bucket: "my-bucket",
Refile.cache = "cache", **aws) = "store", **aws)

I'm not quite sure how the AWS storage works with the resized images. I'm guessing it downloads a copy of the image to your server from S3 and then resizes it, but maybe it's slow to reprocess things.

I wouldn't consider myself a refile expert and I'm not using it in production anywhere, but I would post this on the Refile github issues:

Join the discussion

Want to stay up-to-date with Ruby on Rails?

Join 53,130+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    logo Created with Sketch.

    Ruby on Rails tutorials, guides, and screencasts for web developers learning Ruby, Rails, Javascript, Turbolinks, Stimulus.js, Vue.js, and more. Icons by Icons8

    © 2021 GoRails, LLC. All rights reserved.