Class: LogStasher::Railtie
- Inherits:
-
Rails::Railtie
- Object
- Rails::Railtie
- LogStasher::Railtie
- Defined in:
- lib/logstasher/railtie.rb
Instance Method Summary collapse
Instance Method Details
#default_logger ⇒ Object
47 48 49 50 51 52 53 54 55 56 |
# File 'lib/logstasher/railtie.rb', line 47 def default_logger unless @default_logger path = ::Rails.root.join('log', "logstash_#{::Rails.env}.log") ::FileUtils.touch(path) # prevent autocreate messages in log @default_logger = ::Logger.new(path) end @default_logger end |