added pidfile option for wwclient

This commit is contained in:
Christian Goll
2021-11-12 11:24:26 +01:00
parent 48fefd31ae
commit 93c337a469
3 changed files with 77 additions and 6 deletions

22
cmd/wwclient/main.go Normal file
View File

@@ -0,0 +1,22 @@
package main
import (
"fmt"
"os"
"github.com/hpcng/warewulf/internal/app/wwclient"
)
func main() {
root := wwclient.GetRootCommand()
err := root.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "ERROR: %s\n", err)
if wwclient.DebugFlag {
fmt.Printf("\nSTACK TRACE: %+v\n", err)
}
os.Exit(255)
}
}