From 746fabadfd00cfe37c765309bb21a5feaa089b13 Mon Sep 17 00:00:00 2001 From: Priit Tark Date: Fri, 14 Aug 2015 14:27:30 +0300 Subject: [PATCH] Updated syslog #2292 --- Gemfile | 2 +- Gemfile.lock | 2 +- config/environments/alpha.rb | 7 ++----- config/environments/development.rb | 3 +++ config/environments/production.rb | 2 +- config/environments/staging.rb | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Gemfile b/Gemfile index 6e43bdb2f..57d252870 100644 --- a/Gemfile +++ b/Gemfile @@ -11,7 +11,7 @@ source 'https://rubygems.org' gem 'rails', '4.2.3' # when update, all initializers eis_custom files needs check/update gem 'iso8601', '~> 0.8.6' # for dates and times gem 'hashie-forbidden_attributes', '~> 0.1.1' -gem 'SyslogLogger', '~> 2.0.0' +gem 'SyslogLogger', '~> 2.0', require: 'syslog/logger' # load env gem 'figaro', '~> 1.1.1' diff --git a/Gemfile.lock b/Gemfile.lock index cc0169e38..d8d12b077 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -540,7 +540,7 @@ PLATFORMS ruby DEPENDENCIES - SyslogLogger (~> 2.0.0) + SyslogLogger (~> 2.0) activerecord-import (~> 0.7.0) autodoc better_errors (~> 2.1.1) diff --git a/config/environments/alpha.rb b/config/environments/alpha.rb index aca30bb9a..3d85cc30b 100644 --- a/config/environments/alpha.rb +++ b/config/environments/alpha.rb @@ -48,11 +48,8 @@ Rails.application.configure do # Prepend all log lines with the following tags. config.log_tags = [:subdomain, :uuid, :remote_ip] - # Use a different logger for distributed setups. - # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new(ENV['app_name'])) - - # Use a different logger for distributed setups. - # config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new) + # config.log_tags = [:subdomain, :uuid, :remote_ip] + config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new(ENV['app_name'] || 'registry')) # Use a different cache store in production. # config.cache_store = :mem_cache_store diff --git a/config/environments/development.rb b/config/environments/development.rb index ce01368f9..3c288f2e0 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -35,6 +35,9 @@ Rails.application.configure do # Raises error for missing translations # config.action_view.raise_on_missing_translations = true + # config.log_tags = [:subdomain, :uuid, :remote_ip] + # config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new(ENV['app_name'] || 'registry')) + config.action_mailer.default_url_options = { host: 'localhost:8081' } # for finding database optimization diff --git a/config/environments/production.rb b/config/environments/production.rb index ef1ba2e0a..58258e710 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -49,7 +49,7 @@ Rails.application.configure do config.log_tags = [:subdomain, :uuid, :remote_ip] # Use a different logger for distributed setups. - config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new(ENV['app_name'])) + config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new(ENV['app_name'] || 'registry')) # Use a different cache store in production. # config.cache_store = :mem_cache_store diff --git a/config/environments/staging.rb b/config/environments/staging.rb index a18e9a4c0..0a5e3ecae 100644 --- a/config/environments/staging.rb +++ b/config/environments/staging.rb @@ -49,7 +49,7 @@ Rails.application.configure do config.log_tags = [:subdomain, :uuid, :remote_ip] # Use a different logger for distributed setups. - config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new(ENV['app_name'])) + config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new(ENV['app_name'] || 'registry')) # Use a different cache store in production. # config.cache_store = :mem_cache_store