Skip to content

Commit

Permalink
Merge pull request #24 from unipept/fix/limit-max-log-size
Browse files Browse the repository at this point in the history
Limit Rails log files to 500MiB in production
  • Loading branch information
pverscha authored Aug 11, 2023
2 parents 596edd2 + 260b6cd commit 54ee9c1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions config/environments/production.rb
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@
# Use a different logger for distributed setups.
# require "syslog/logger"
# config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new "app-name")
config.logger = ActiveSupport::Logger.new(config.paths["log"].first, 1, 500 * 1024 * 1024) # 50 MB

if ENV["RAILS_LOG_TO_STDOUT"].present?
logger = ActiveSupport::Logger.new(STDOUT)
Expand Down

0 comments on commit 54ee9c1

Please sign in to comment.