moved location of defaults.conf

Signed-off-by: Christian Goll <cgoll@suse.de>
This commit is contained in:
Christian Goll
2023-03-07 11:49:09 +01:00
parent 3367b67b9f
commit 07d39c2e49
5 changed files with 4 additions and 15 deletions

View File

@@ -44,7 +44,7 @@ func init() {
ConfigFile = path.Join(conf.Paths.Sysconfdir, "warewulf/nodes.conf")
}
if DefaultConfig == "" {
DefaultConfig = path.Join(conf.Paths.Sysconfdir, "warewulf/defaults.conf")
DefaultConfig = path.Join(conf.Paths.Datadir, "warewulf/defaults.conf")
}
cachedDB.current = false
cachedDB.persist = true
@@ -114,12 +114,6 @@ for every node
*/
func (config *NodeYaml) FindAllNodes() ([]NodeInfo, error) {
var ret []NodeInfo
/*
wwconfig, err := warewulfconf.New()
if err != nil {
return ret, err
}
*/
var defConf map[string]*NodeConf
wwlog.Verbose("Opening defaults from file failed %s\n", DefaultConfig)
defData, err := os.ReadFile(DefaultConfig)