I wondered if it was an issue specific to Heroku, so I setup the Paperclip AWS config to test locally to no avail; I was still getting the same error. I immediately went to Google and tried all of the solutions I came across on Github and Stack Overflow to no avail; my problem persisted. I finally came across a post on Stack Overflow that had a similar error, and in the comments, someone suggested using the 5.0.0.beta2 version of the Paperclip gem. I updated my Gemfile to use that version: gem 'paperclip', '5.0.0.beta2' and after a bundle install - file uploads were working! I did have to specify the s3_host_name in my paperclip config to get images to display, but it worked. Since I haven't come across much information on this on the web, I thought I'd make a post about it. So if anyone else is having this issue, update your Gemfile to use a version of the Paperclip gem > 5.0. I updated mine to use Paperclip 5.1.0 and everything is working great.
gem 'paperclip', '5.1.0'With the paperclip config as follows:
config.paperclip_defaults = {
storage: :s3,
s3_credentials: {
bucket: ENV.fetch('S3_BUCKET_NAME'),
access_key_id: ENV.fetch('AWS_ACCESS_KEY_ID'),
secret_access_key: ENV.fetch('AWS_SECRET_ACCESS_KEY'),
s3_region: ENV.fetch('AWS_REGION'),
s3_host_name: ENV.fetch('S3_HOST_NAME'),
}
}
Cheers.
Harrah's Cherokee Casinos - MapyRO
ReplyDeleteThis map 화성 출장마사지 shows Harrah's Cherokee 나주 출장안마 Casinos and their location. Casinos and Hotels in 거제 출장샵 Cherokee, NC. Show 경상북도 출장마사지 map. 강원도 출장안마
The King Casino | Situs Judi Slot Online Terbaik 2021
ReplyDeletePlay online 토토 Pragmatic Play Slots herzamanindir.com/ at The https://septcasino.com/review/merit-casino/ King Casino - 바카라 사이트 Member Baru & Terpercaya 2021! Rating: 98% · 240,388 wooricasinos.info votes