toggle json logging via config

This commit is contained in:
Igor Perepilitsyn 2022-06-18 15:00:47 +03:00
parent cc0bec15ef
commit 2403c0e198
3 changed files with 9 additions and 0 deletions

View file

@ -55,6 +55,10 @@ func initConfig() {
zerolog.SetGlobalLevel(zerolog.Disabled)
}
if cfg.JSONLogs {
log.Logger = log.Output(os.Stdout)
}
if !cfg.DisableUpdateCheck && !machineOutput {
if (runtime.GOOS == "linux" || runtime.GOOS == "darwin") &&
Version != "dev" {