diff --git a/db/seeds/backer.rb b/db/seeds/backer.rb index 877ffc13f6c3bb93951916c78c0bf92e7e1d277b..269772f517898525c1dfea822160c830c83cb2a5 100644 --- a/db/seeds/backer.rb +++ b/db/seeds/backer.rb @@ -13,7 +13,8 @@ def create #set pod url username = backer_info[backer_number]['username'].gsub(/ /,'').downcase - set_app_config username + set_app_config username unless File.exists?(Rails.root.join('config', 'app_config.yml')) + require File.join(File.dirname(__FILE__), "..", "..", "config", "initializers", "_load_app_config.rb") # Create seed user diff --git a/db/seeds/dev.rb b/db/seeds/dev.rb index 33f7736130abf4d5e12efd9a2729125376dab214..324cf47bdb2fa8a7751d450370d2401a597c1897 100644 --- a/db/seeds/dev.rb +++ b/db/seeds/dev.rb @@ -15,7 +15,9 @@ def set_app_config username end username = "tom" -set_app_config username +set_app_config username unless File.exists?(Rails.root.join('config', 'app_config.yml')) + +require Rails.root.join('config', "initializers", "_load_app_config.rb") # Create seed user user = User.build( :email => "tom@tom.joindiaspora.com", diff --git a/db/seeds/tom.rb b/db/seeds/tom.rb index f4c453d8194944a5f99bc06a87d5e1c047db65ff..fe45e2dd02454a6b481a5de34e80ca0ad64dd045 100644 --- a/db/seeds/tom.rb +++ b/db/seeds/tom.rb @@ -14,7 +14,8 @@ def set_app_config username file.close end -set_app_config "tom" +set_app_config "tom" unless File.exists?(Rails.root.join('config', 'app_config.yml')) + require 'config/initializers/_load_app_config.rb' # Create seed user