Update monolog configuration with parameterized log prefix and additional handlers
Replaced hardcoded 'test' log prefix with `{{ chill.chill_environment }}` variable. Added `errors_log` handler for error-level logging and `deprecation_log` handler to suppress deprecation warnings. Updated channel exclusions and console handler level for improved log management.
This commit is contained in:
1 file changed
+13
-3
@@ -6,7 +6,7 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
parameters:
|
parameters:
|
||||||
log_prefix: 'test'
|
log_prefix: '{{ chill.chill_environment }}'
|
||||||
monolog:
|
monolog:
|
||||||
# make a "notifier" channel available
|
# make a "notifier" channel available
|
||||||
channels: ['notifier']
|
channels: ['notifier']
|
||||||
@@ -16,6 +16,10 @@ monolog:
|
|||||||
path: "%kernel.logs_dir%/notifier-%log_prefix%.log"
|
path: "%kernel.logs_dir%/notifier-%log_prefix%.log"
|
||||||
level: info
|
level: info
|
||||||
channels: [ 'notifier' ]
|
channels: [ 'notifier' ]
|
||||||
|
errors_log:
|
||||||
|
type: stream
|
||||||
|
path: "%kernel.logs_dir%/error-%log_prefix%.log"
|
||||||
|
level: error
|
||||||
privacy_log:
|
privacy_log:
|
||||||
type: stream
|
type: stream
|
||||||
path: "%kernel.logs_dir%/privacy-%log_prefix%.log"
|
path: "%kernel.logs_dir%/privacy-%log_prefix%.log"
|
||||||
@@ -25,9 +29,15 @@ monolog:
|
|||||||
type: stream
|
type: stream
|
||||||
path: "%kernel.logs_dir%/default-%log_prefix%.log"
|
path: "%kernel.logs_dir%/default-%log_prefix%.log"
|
||||||
level: info
|
level: info
|
||||||
channels: [ '!event', '!doctrine', '!console', '!chill',]
|
channels: [ '!event', '!doctrine', '!console', '!chill', '!deprecation']
|
||||||
|
deprecation_log:
|
||||||
|
type: 'null'
|
||||||
|
channels: [ 'deprecation' ]
|
||||||
console:
|
console:
|
||||||
type: console
|
type: console
|
||||||
process_psr_3_messages: false
|
process_psr_3_messages: false
|
||||||
channels: [ '!event', '!doctrine', '!console']
|
level: error
|
||||||
|
channels: [ '!event', '!doctrine', '!console', '!deprecation']
|
||||||
bubble: true
|
bubble: true
|
||||||
|
|
||||||
|
|
||||||
Reference in new issue
Block a user