mirror of
https://github.com/datarhei/core.git
synced 2025-09-26 20:11:29 +08:00
Test different standard location for config file
If no path is given in the environment variable CORE_CONFIGFILE, different standard locations will be probed: - os.UserConfigDir() + /datarhei-core/config.js - os.UserHomeDir() + /.config/datarhei-core/config.js - ./config/config.js If the config.js doesn't exist in any of these locations, it will be assumed at ./config/config.js
This commit is contained in:
@@ -229,6 +229,8 @@ func (a *api) Reload() error {
|
||||
|
||||
logger.Info().WithFields(logfields).Log("")
|
||||
|
||||
logger.Info().WithField("path", a.config.path).Log("Read config file")
|
||||
|
||||
configlogger := logger.WithComponent("Config")
|
||||
cfg.Messages(func(level string, v configvars.Variable, message string) {
|
||||
configlogger = configlogger.WithFields(log.Fields{
|
||||
|
Reference in New Issue
Block a user