mirror of
https://github.com/netbirdio/netbird.git
synced 2026-07-22 00:11:29 +02:00
Fix default log level
This commit is contained in:
@@ -21,8 +21,9 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
metricsPort = 9090
|
||||
defaultLogPath = "console"
|
||||
metricsPort = 9090
|
||||
defaultLogLevel = "info"
|
||||
defaultLogPath = "console"
|
||||
)
|
||||
|
||||
type Config struct {
|
||||
@@ -147,6 +148,10 @@ func loadConfig(configFile string) (*Config, error) {
|
||||
loadedConfig.LetsencryptAWSSecretAccessKey = cobraConfig.LetsencryptAWSSecretAccessKey
|
||||
}
|
||||
|
||||
if loadedConfig.LogLevel == "" {
|
||||
loadedConfig.LogLevel = defaultLogLevel
|
||||
}
|
||||
|
||||
if loadedConfig.LogFile == "" {
|
||||
loadedConfig.LogFile = defaultLogPath
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user