When I run cap production deploy I keep running into this error with carrier wave. I have posted my carrierwave settings below.
Tasks: TOP => deploy:assets:precompile
The deploy has failed with an error: Exception while executing as deploy@104.236.193.148: rake exit status: 1
rake stdout: Nothing written
rake stderr: rake aborted!
LoadError: cannot load such file -- carrierwave/processing/mime_types
/home/deploy/aldrinclement/shared/bundle/ruby/2.3.0/gems/activesupport- 4.2.6/lib/active_support/dependencies.rb:274:in `require'
/home/deploy/aldrinclement/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `block in require'
/home/deploy/aldrinclement/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:240:in `load_dependency'
/home/deploy/aldrinclement/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `require'
/home/deploy/aldrinclement/releases/20170103201423/app/uploaders/author_image_uploader.rb:1:in `<top (required)>'
Carrierwave.rb
if Rails.env.production? || Rails.env.staging?
CarrierWave.configure do |config|
config.fog_credentials = {
provider: 'AWS',
aws_access_key_id: Rails.application.secrets.AWS_ACCESS_KEY_ID,
aws_secret_access_key: Rails.application.secrets.AWS_SECRET_ACCESS_KEY,
region: Settings.aws_region
}
config.fog_directory = Settings.aws_s3_bucket_name
config.permissions = 0666
config.directory_permissions = 0777
config.storage = :fog
end
end
CarrierWave::SanitizedFile.sanitize_regexp = /[^[:word:]\.\-\+]/
My secrets.yml has the AWS keys defined - I had run into missing aws keys and solved that issue with secrets.yml symlinked in my deploy.rb file. I'm using carrierwave 1.0.0 in my Gemfile.