From 6c4e5da5f6e163900f4af94892af387760ff117e Mon Sep 17 00:00:00 2001 From: Priit Tark Date: Thu, 15 Jan 2015 17:12:59 +0200 Subject: [PATCH] added api log to database example --- app/models/api_log/db.rb | 2 +- config/database-example.yml | 19 +++++++++++++++++-- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/app/models/api_log/db.rb b/app/models/api_log/db.rb index 4c929147a..0e908818d 100644 --- a/app/models/api_log/db.rb +++ b/app/models/api_log/db.rb @@ -1,6 +1,6 @@ module ApiLog class Db < ActiveRecord::Base self.abstract_class = true - establish_connection "api_log_#{Rails.env}".to_sym + establish_connection "api_log_#{Rails.env}" end end diff --git a/config/database-example.yml b/config/database-example.yml index 5f708f07b..c9078e0f2 100644 --- a/config/database-example.yml +++ b/config/database-example.yml @@ -11,21 +11,36 @@ development: <<: *default database: registry_development -development: +whois_development: <<: *default database: registry_whois_development +api_log_development: + <<: *default + database: api_log_development + test: <<: *default database: registry_test +whois_test: + <<: *default + database: registry_whois_test + +api_log_test: + <<: *default + database: api_log_test + production: <<: *default database: registry_production -production: +whois_production: <<: *default database: registry_whois_production +api_log_production: + <<: *default + database: api_log_production