Commit 2dce0f09f151d34d6ef66ac6f17163e483469f16
1 parent
804bc020
Exists in
master
and in
1 other branch
check for MONGODB_URL if USE_ENV or HEROKU is set
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
config/initializers/mongo.rb
@@ -6,7 +6,7 @@ if config_file.file? && | @@ -6,7 +6,7 @@ if config_file.file? && | ||
6 | elsif ENV['HEROKU'] || ENV['USE_ENV'] | 6 | elsif ENV['HEROKU'] || ENV['USE_ENV'] |
7 | # No mongoid.yml file. Use ENV variable to define your MongoDB | 7 | # No mongoid.yml file. Use ENV variable to define your MongoDB |
8 | # configuration | 8 | # configuration |
9 | - if mongo = ENV['MONGOLAB_URI'] || ENV['MONGOHQ_URL'] | 9 | + if mongo = ENV['MONGOLAB_URI'] || ENV['MONGOHQ_URL'] || ENV['MONGODB_URL'] |
10 | settings = URI.parse(mongo) | 10 | settings = URI.parse(mongo) |
11 | database_name = settings.path.gsub(/^\//, '') | 11 | database_name = settings.path.gsub(/^\//, '') |
12 | else | 12 | else |