diff options
author | gebele <gebele@in-silico.ch> | 2018-05-04 14:45:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-04 14:45:29 +0200 |
commit | 8eae9776708c93bc4a6d713b3de3e9060b43c737 (patch) | |
tree | 606872b88895d2bfbcfcc01669009758e7cc6755 /lib | |
parent | 91f0cfc13cb5c5e8d10f9321e68ed0304068a234 (diff) |
use previouse method to get mongo ipORN
Diffstat (limited to 'lib')
-rw-r--r-- | lib/lazar.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/lazar.rb b/lib/lazar.rb index 1f909b7..942fc01 100644 --- a/lib/lazar.rb +++ b/lib/lazar.rb @@ -19,7 +19,7 @@ ENV["MONGOID_ENV"] = ENV["LAZAR_ENV"] ENV["RACK_ENV"] = ENV["LAZAR_ENV"] # should set sinatra environment # search for a central mongo database in use # http://opentox.github.io/installation/2017/03/07/use-central-mongodb-in-docker-environment -CENTRAL_MONGO_IP = "mongodb" +CENTRAL_MONGO_IP = `grep -oP '^\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}(?=.*mongodb)' /etc/hosts`.chomp Mongoid.load_configuration({ :clients => { :default => { |