summaryrefslogtreecommitdiffstats
path: root/lib/xdsconfig
diff options
context:
space:
mode:
authorSebastien Douheret <sebastien.douheret@iot.bzh>2017-10-11 09:36:05 +0200
committerSebastien Douheret <sebastien.douheret@iot.bzh>2017-11-06 15:57:04 +0100
commit8119c1641e88ee5020e380c08119f508c6e24222 (patch)
tree5b295fb9e210b9bf5cee52fdb4fcb16d6878fd27 /lib/xdsconfig
parenta3d2ca72d05d28b1ae5820787ff696dd75fd17cc (diff)
Add Server UUID and use it build CmdID.
Diffstat (limited to 'lib/xdsconfig')
-rw-r--r--lib/xdsconfig/config.go7
-rw-r--r--lib/xdsconfig/fileconfig.go2
2 files changed, 6 insertions, 3 deletions
diff --git a/lib/xdsconfig/config.go b/lib/xdsconfig/config.go
index 2f1fa96..0fc1346 100644
--- a/lib/xdsconfig/config.go
+++ b/lib/xdsconfig/config.go
@@ -88,6 +88,8 @@ func Init(cliCtx *cli.Context, log *logrus.Logger) (*Config, error) {
Log: log,
}
+ c.Log.Infoln("Server UUID: ", uuid)
+
// config file settings overwrite default config
err = readGlobalConfig(&c, c.Options.ConfigFile)
if err != nil {
@@ -130,8 +132,9 @@ func Init(cliCtx *cli.Context, log *logrus.Logger) (*Config, error) {
return nil, fmt.Errorf("Cannot create logs dir: %v", err)
}
}
- c.Log.Infoln("Logs file: ", c.Options.LogFile)
- c.Log.Infoln("Logs directory: ", c.FileConf.LogsDir)
+
+ c.Log.Infoln("Logs file: ", c.Options.LogFile)
+ c.Log.Infoln("Logs directory: ", c.FileConf.LogsDir)
return &c, nil
}
diff --git a/lib/xdsconfig/fileconfig.go b/lib/xdsconfig/fileconfig.go
index 39560a4..dafb034 100644
--- a/lib/xdsconfig/fileconfig.go
+++ b/lib/xdsconfig/fileconfig.go
@@ -84,7 +84,7 @@ func readGlobalConfig(c *Config, confFile string) error {
// No config file found
return nil
}
- c.Log.Infof("Use config file: %s", *cFile)
+ c.Log.Infof("Use config file: %s", *cFile)
// TODO move on viper package to support comments in JSON and also
// bind with flags (command line options)