Lots of changes including: wwctl overlay list and framework for other commands

This commit is contained in:
Gregory Kurtzer
2020-11-16 21:37:55 -08:00
parent 52eb51e38a
commit 85603ee947
19 changed files with 484 additions and 34 deletions

View File

@@ -19,7 +19,7 @@ func main() {
time.Sleep(5000 * time.Millisecond)
} else {
fmt.Printf("Called via: %s\n", os.Args[0])
fmt.Printf("Runtime system-overlay is being put in '/warewulf/wwclient-test' rather than '/'\n")
fmt.Printf("Runtime overlay is being put in '/warewulf/wwclient-test' rather than '/'\n")
os.MkdirAll("/warewulf/wwclient-test", 0755)
os.Chdir("/warewulf/wwclient-test")
}
@@ -74,12 +74,12 @@ func main() {
}
if resp.StatusCode != 200 {
log.Printf("Not updating runtime system-overlay, got status code: %d\n", resp.StatusCode)
log.Printf("Not updating runtime overlay, got status code: %d\n", resp.StatusCode)
time.Sleep(60000 * time.Millisecond)
continue
}
log.Printf("Updating runtime system\n")
log.Printf("Updating system\n")
command := exec.Command("/bin/cpio", "-iu")
command.Stdin = resp.Body
err := command.Run()