fog, aws not supported any more
This commit is contained in:
parent
7acec90448
commit
19b95fe4a4
3
Gemfile
3
Gemfile
|
@ -12,8 +12,7 @@ gem "carrierwave", :git => 'git://github.com/jnicklas/carrierwave.git'
|
|||
gem 'sqlite3-ruby'
|
||||
|
||||
# S3 support
|
||||
#gem 'fog'
|
||||
gem 'aws'
|
||||
gem 'fog'
|
||||
|
||||
# ImageMagick:
|
||||
#gem "rmagick", :require => 'RMagick'
|
||||
|
|
25
Gemfile.lock
25
Gemfile.lock
|
@ -36,16 +36,22 @@ GEM
|
|||
activesupport (= 3.0.6)
|
||||
activesupport (3.0.6)
|
||||
arel (2.0.9)
|
||||
aws (2.4.5)
|
||||
activesupport
|
||||
http_connection
|
||||
uuidtools
|
||||
xml-simple
|
||||
builder (2.1.2)
|
||||
erubis (2.6.6)
|
||||
abstract (>= 1.0.0)
|
||||
http_connection (1.4.0)
|
||||
excon (0.6.1)
|
||||
fog (0.7.2)
|
||||
builder
|
||||
excon (>= 0.6.1)
|
||||
formatador (>= 0.1.3)
|
||||
json
|
||||
mime-types
|
||||
net-ssh (>= 2.1.3)
|
||||
nokogiri (>= 1.4.4)
|
||||
ruby-hmac
|
||||
formatador (0.1.3)
|
||||
i18n (0.5.0)
|
||||
json (1.5.1)
|
||||
mail (2.2.15)
|
||||
activesupport (>= 2.3.6)
|
||||
i18n (>= 0.4.0)
|
||||
|
@ -55,6 +61,8 @@ GEM
|
|||
mini_exiftool (1.3.0)
|
||||
mini_magick (3.2)
|
||||
subexec (~> 0.0.4)
|
||||
net-ssh (2.1.4)
|
||||
nokogiri (1.4.4)
|
||||
polyglot (0.3.1)
|
||||
rack (1.2.2)
|
||||
rack-mount (0.6.14)
|
||||
|
@ -75,6 +83,7 @@ GEM
|
|||
rake (>= 0.8.7)
|
||||
thor (~> 0.14.4)
|
||||
rake (0.8.7)
|
||||
ruby-hmac (0.4.0)
|
||||
sqlite3 (1.3.3)
|
||||
sqlite3-ruby (1.3.3)
|
||||
sqlite3 (>= 1.3.3)
|
||||
|
@ -83,15 +92,13 @@ GEM
|
|||
treetop (1.4.9)
|
||||
polyglot (>= 0.3.1)
|
||||
tzinfo (0.3.26)
|
||||
uuidtools (2.1.2)
|
||||
xml-simple (1.0.15)
|
||||
|
||||
PLATFORMS
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
aws
|
||||
carrierwave!
|
||||
fog
|
||||
mime-types
|
||||
mini_exiftool
|
||||
mini_magick
|
||||
|
|
|
@ -8,7 +8,7 @@ class FileUploader < CarrierWave::Uploader::Base
|
|||
include CarrierWave::MiniMagick
|
||||
# Choose what kind of storage to use for this uploader
|
||||
if ENV['S3_KEY']
|
||||
storage :s3
|
||||
storage :fog
|
||||
|
||||
def cache_dir
|
||||
"#{RAILS_ROOT}/tmp/uploads" if ENV['HEROKU'] == 'true'
|
||||
|
|
|
@ -1,12 +1,9 @@
|
|||
CarrierWave.configure do |config|
|
||||
config.s3_access_key_id = ENV['S3_KEY']
|
||||
config.s3_secret_access_key = ENV['S3_SECRET']
|
||||
config.s3_bucket = ENV['S3_BUCKET']
|
||||
#config.fog_credentials = {
|
||||
# :provider => 'AWS',
|
||||
# :aws_access_key_id => ENV['S3_KEY'],
|
||||
# :aws_secret_access_key => ENV['S3_SECRET'],
|
||||
# :region => 'us-east-1'
|
||||
#}
|
||||
#config.fog_directory = ENV['S3_BUCKET']
|
||||
config.fog_credentials = {
|
||||
:provider => 'AWS',
|
||||
:aws_access_key_id => ENV['S3_KEY'],
|
||||
:aws_secret_access_key => ENV['S3_SECRET'],
|
||||
:region => 'us-east-1'
|
||||
}
|
||||
config.fog_directory = ENV['S3_BUCKET']
|
||||
end
|
Loading…
Reference in a new issue