proxy: output JSON logs

This commit is contained in:
Jens Langhammer 2020-12-14 19:41:32 +01:00
parent 5c4163579b
commit 51d07f7913
1 changed files with 1 additions and 0 deletions

View File

@ -59,6 +59,7 @@ func getCommonOptions() *options.Options {
} }
func doGlobalSetup(config map[string]interface{}) { func doGlobalSetup(config map[string]interface{}) {
log.SetFormatter(&log.JSONFormatter{})
switch config[ConfigLogLevel].(string) { switch config[ConfigLogLevel].(string) {
case "debug": case "debug":
log.SetLevel(log.DebugLevel) log.SetLevel(log.DebugLevel)