action-env/cmd/frostfs-node/config/logger/config.go
Alex Vanin 20de74a505 Rename package name
Due to source code relocation from GitHub.

Signed-off-by: Alex Vanin <a.vanin@yadro.com>
2023-03-07 16:38:26 +03:00

26 lines
478 B
Go

package loggerconfig
import (
"git.frostfs.info/TrueCloudLab/frostfs-node/cmd/frostfs-node/config"
)
const (
// LevelDefault is a default logger level.
LevelDefault = "info"
)
// Level returns the value of "level" config parameter
// from "logger" section.
//
// Returns LevelDefault if the value is not a non-empty string.
func Level(c *config.Config) string {
v := config.StringSafe(
c.Sub("logger"),
"level",
)
if v != "" {
return v
}
return LevelDefault
}