Added error logging to file in logging.conf
All checks were successful
Amarillo/amarillo-gitea/amarillo-core/pipeline/head This commit looks good
All checks were successful
Amarillo/amarillo-gitea/amarillo-core/pipeline/head This commit looks good
This commit is contained in:
parent
3ed38a959d
commit
6f019020ea
|
|
@ -2,14 +2,14 @@
|
||||||
keys=root
|
keys=root
|
||||||
|
|
||||||
[handlers]
|
[handlers]
|
||||||
keys=consoleHandler
|
keys=consoleHandler, fileHandler
|
||||||
|
|
||||||
[formatters]
|
[formatters]
|
||||||
keys=simpleFormatter
|
keys=simpleFormatter
|
||||||
|
|
||||||
[logger_root]
|
[logger_root]
|
||||||
level=INFO
|
level=INFO
|
||||||
handlers=consoleHandler
|
handlers=consoleHandler, fileHandler
|
||||||
propagate=yes
|
propagate=yes
|
||||||
|
|
||||||
[handler_consoleHandler]
|
[handler_consoleHandler]
|
||||||
|
|
@ -18,5 +18,11 @@ level=DEBUG
|
||||||
formatter=simpleFormatter
|
formatter=simpleFormatter
|
||||||
args=(sys.stdout,)
|
args=(sys.stdout,)
|
||||||
|
|
||||||
|
[handler_fileHandler]
|
||||||
|
class=handlers.RotatingFileHandler
|
||||||
|
level=ERROR
|
||||||
|
formatter=simpleFormatter
|
||||||
|
args=('error.log', 'a', 1000000, 3) # Filename, mode, maxBytes, backupCount
|
||||||
|
|
||||||
[formatter_simpleFormatter]
|
[formatter_simpleFormatter]
|
||||||
format=%(asctime)s - %(name)s - %(levelname)s - %(message)s
|
format=%(asctime)s - %(name)s - %(levelname)s - %(message)s
|
||||||
Loading…
Reference in a new issue