A free open source IT asset/license management system
Fixes #4226 - adds log_max_files to app config and sample env
snipeaa7091d9624b
diff --git a/.env.example b/.env.exampleindex 2a34e9ae2c..51f9e3e5b2 100644--- a/.env.example+++ b/.env.example@@ -97,7 +97,8 @@ LOGIN_LOCKOUT_DURATION=60# --------------------------------------------# OPTIONAL: MISC# ---------------------------------------------APP_LOG=single+APP_LOG=daily+APP_LOG_MAX_FILES=10APP_LOCKED=falseFILESYSTEM_DISK=localAPP_TRUSTED_PROXIES=192.168.1.1,10.0.0.1diff --git a/app/Providers/AppServiceProvider.php b/app/Providers/AppServiceProvider.phpindex 0e885f1045..9aea69bec7 100644--- a/app/Providers/AppServiceProvider.php+++ b/app/Providers/AppServiceProvider.php@@ -98,8 +98,8 @@ class AppServiceProvider extends ServiceProviderif (config('app.debug')) {$log_level = 'debug';} else {- if (config('log-level')) {- $log_level = config('log-level');+ if (config('app.log_level')) {+ $log_level = config('app.log_level');} else {$log_level = 'error';}diff --git a/config/app.php b/config/app.phpindex 6c9c471a5a..08befc2366 100755--- a/config/app.php+++ b/config/app.php@@ -121,8 +121,41 @@ return [|*/- 'log' => env('APP_LOG', 'single'),- 'log-level' => env('APP_LOG_LEVEL', 'error'),+ 'log' => env('APP_LOG', 'daily'),++ /*+ |--------------------------------------------------------------------------+ | Logging Max Files+ |--------------------------------------------------------------------------+ |+ | When using the daily log mode, Laravel will only retain 5+ | days of log files by default.+ |+ | To change this, set the APP_LOG_MAX_FILES option in your .env.+ |+ */++ 'log_max_files' => env('APP_LOG_MAX_FILES', 5),++ /*+ |--------------------------------------------------------------------------+ | Logging Detail+ |--------------------------------------------------------------------------+ |+ | By default, Laravel writes all log levels to storage. However, in your+ | production environment, you may wish to configure the minimum severity that+ | should be logged by editing your APP_LOG_LEVEL env config.+ |+ | Laravel will log all levels greater than or equal to the specified severity.+ | For example, a default log_level of error will log error, critical, alert,+ | and emergency messages.+ |+ | APP_LOG_LEVEL options are:+ | "debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"+ |+ */++ 'log_level' => env('APP_LOG_LEVEL', 'error'),/*