Add config option for shared state dir

Signed-off-by: jcsiadal <jeremy.c.siadal@intel.com>

Changes default share to /srv/warewulf
Update specfile
Some changes to match Golang standards
This commit is contained in:
jcsiadal
2021-12-14 04:37:39 +00:00
parent 72290a3a3d
commit 8e626e9a62
18 changed files with 229 additions and 80 deletions

View File

@@ -0,0 +1,26 @@
package main
// Regenerates the default configuration files
// Keeps the current content and adds missing default values
// Won't create a new file, but will update a blank file
//TODO: Add nodes.conf
import (
"fmt"
"github.com/hpcng/warewulf/internal/pkg/warewulfconf"
)
func main() {
tmpConf, err := warewulfconf.New()
if err != nil {
fmt.Println(err)
return
}
err = tmpConf.Persist()
if err != nil {
fmt.Println(err)
return
}
}