This gem allows to store carrierwave
uploads in the database, eg. on platforms with ephemeral filesystems like Heroku.
# In: Gemfile
gem 'carrierwave-blob', github: "samvincent/carrierwave-blob"
- Setup your uploader to use the blob storage:
# In: app/uploaders/picture_uploader.rb
storage CarrierWave::Storage::Blob
- Generate a migration for your model:
rails generate carrier_wave_blob_migration Idea
- Execute the migrations:
rake db:migrate
This is a fork of a found gist by @karmi.