Commit a9f23e20 authored by Sietse Ringers's avatar Sietse Ringers
Browse files

Log config file unmarshaling errors

parent fb068f80
......@@ -100,7 +100,11 @@ func configure() error {
logger.Debugf("Configuring")
if err != nil {
logger.Info("No configuration file found")
if _, notfound := err.(viper.ConfigFileNotFoundError); notfound {
logger.Info("No configuration file found")
} else {
die(errors.WrapPrefix(err, "Failed to unmarshal configuration file at "+viper.ConfigFileUsed(), 0))
}
} else {
logger.Info("Config file: ", viper.ConfigFileUsed())
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment