Sha256: 511b89a329e430ea343fb0752fbb75e03d40f34af5754402c6a7d54345c90b5e
Contents?: true
Size: 605 Bytes
Versions: 7
Compression:
Stored size: 605 Bytes
Contents
class RoquaLoggingRailtie < Rails::Railtie config.after_initialize do |app| RoquaLoggingRailtie.configure end class << self def configure Roqua.logger = ActiveSupport::Logger.new(output_stream).tap do |logger| logger.formatter = Logger::Formatter.new end require 'roqua/support/request_logger' Roqua::Support::RequestLogger.attach_to :action_controller end def output_stream if ENV['RAILS_LOG_TO_STDOUT_USING_ROQUA_LOGGER'].present? STDOUT else Rails.root.join("log/#{Rails.env}-events.log") end end end end
Version data entries
7 entries across 7 versions & 1 rubygems