parent
f7959d3333
commit
f9bf88c55f
|
@ -29,12 +29,12 @@ const dateTimeFormatAlt = "2006-01-02 15:04:05"
|
||||||
const dateFormatAlt = "1/2/2006"
|
const dateFormatAlt = "1/2/2006"
|
||||||
|
|
||||||
// InitConfig exports the config initialization func
|
// InitConfig exports the config initialization func
|
||||||
func InitConfig(systemName string) {
|
func InitConfig(systemName string, initalLogLevel zapcore.Level) {
|
||||||
if configured {
|
if configured {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
sugar = logger.New(zapcore.InfoLevel)
|
sugar = logger.New(initalLogLevel)
|
||||||
sugar.Info("app.InitConfig: 📥 %s", systemName)
|
sugar.Infof("app.InitConfig: 📥 %s", systemName)
|
||||||
appViper.SetConfigType("yaml")
|
appViper.SetConfigType("yaml")
|
||||||
appViper.SetConfigName(systemName)
|
appViper.SetConfigName(systemName)
|
||||||
appViper.AddConfigPath("/etc/taxnexus")
|
appViper.AddConfigPath("/etc/taxnexus")
|
||||||
|
|
Loading…
Reference in New Issue