specify fog storage

This commit is contained in:
Espen Antonsen 2011-05-08 20:59:52 +08:00
parent 5a3913e936
commit 3a351232c4

View file

@ -8,7 +8,7 @@ class FileUploader < CarrierWave::Uploader::Base
include CarrierWave::MiniMagick include CarrierWave::MiniMagick
# Choose what kind of storage to use for this uploader # Choose what kind of storage to use for this uploader
if ENV['S3_KEY'] if ENV['S3_KEY']
storage :s3 storage :fog
def cache_dir def cache_dir
"#{Rails.root.to_s}/tmp/uploads" if ENV['HEROKU'] == 'true' "#{Rails.root.to_s}/tmp/uploads" if ENV['HEROKU'] == 'true'