0
gem "mini_magick"
gem "refile", require: ["refile/rails", "refile/image_processing"]
gem "aws-sdk"
My config/initializers/refile.Rb file
require "refile/backend/s3"
aws = {
access_key_id: ENV['S3_ACCESS_KEY'],
secret_access_key: ENV['S3_SECRET_ACCESS_KEY'],
bucket: ENV['S3_BUCKET'],
}
Refile.cache = Refile::Backend::S3.new(prefix: "cache", **aws)
Refile.store = Refile::Backend::S3.new(prefix: "store", **aws)
When running Rails, shows this error:
/usr/local/Cellar/ruby/2.2.0/lib/ruby/Gems/2.2.0/Gems/refile-0.4.2/lib/refile/backend/S3.Rb:14:in `initialize': uninitialized Constant Refile::Backend::S3::AWS (Namroreer)
Ruby 2.2.0, Rails 4.2.0
– Thiago Porto