diff options
| author | Jeff Carr <[email protected]> | 2025-10-07 10:13:49 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-10-07 10:13:49 -0500 |
| commit | 79addd26bb68bc8ebb3c56e68b5c1dc636a1db62 (patch) | |
| tree | 1a064d1192d15347d21cb2349502a8bffaeae07e /daemon.go | |
| parent | 8c3e803f27d5af38630da914152858789dbff615 (diff) | |
Diffstat (limited to 'daemon.go')
| -rw-r--r-- | daemon.go | 14 |
1 files changed, 11 insertions, 3 deletions
@@ -9,6 +9,7 @@ import ( "time" "go.wit.com/lib/debian" + "go.wit.com/log" ) // timeFunction takes a function as an argument and returns the execution time. @@ -29,9 +30,16 @@ func zood() { fmt.Println("Done!") return case _ = <-me.dog.C: - s := debian.UpdatePackages(me.machine) - me.failcount += 1 - sendMachine(s) + err := debian.UpdatePackages(me.machine) + if err != nil { + log.Info("UpdatePackages err", err) + me.failcount += 1 + } + err = sendMachine(me.machine) + if err != nil { + log.Info("sendMachine err", err) + me.failcount += 1 + } if me.failcount > 20 { os.Exit(0) |
