mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
Reduce test logging by default
These logs are rarely checked, and can take up a lot of disk space. I wanted to reduce the dev log level too, but then realised it also affects the dev server stdout. So now the other suggestions seem like a good idea.. (eg link development.log to /dev/null) Oh well, this change will at least reduce one source of unnecessary disk usage in a default installation, so I think worth doing.
This commit is contained in:
@@ -27,6 +27,8 @@ Rails.application.configure do
|
||||
# To override this, set the appropriate locale in .env[.*] file.
|
||||
config.time_zone = ENV.fetch("TIMEZONE", "UTC")
|
||||
|
||||
# Log level for dev server stdout and development.log file.
|
||||
# Set the desired level in .env.development.local file.
|
||||
config.log_level = ENV.fetch("RAILS_LOG_LEVEL", :debug)
|
||||
|
||||
# Enable/disable caching. By default caching is disabled.
|
||||
|
||||
@@ -66,8 +66,8 @@ Rails.application.configure do
|
||||
# Tell Active Support which deprecation messages to disallow.
|
||||
config.active_support.disallowed_deprecation_warnings = []
|
||||
|
||||
# Change to reduce unecessary logging
|
||||
config.log_level = ENV.fetch("RAILS_LOG_LEVEL", :debug)
|
||||
# Reduced logging by default; set the desired level in .env.test.local file.
|
||||
config.log_level = ENV.fetch("RAILS_LOG_LEVEL", :fatal)
|
||||
|
||||
# Fail tests on deprecated code unless it's a known case to solve.
|
||||
Rails.application.deprecators.behavior = ->(message, callstack, deprecator) do
|
||||
|
||||
Reference in New Issue
Block a user