diff --git a/cmd/status.go b/cmd/status.go index 55a47a3..6932a7c 100644 --- a/cmd/status.go +++ b/cmd/status.go @@ -102,6 +102,11 @@ var statusCmd = &cobra.Command{ logrus.Fatal(err) } fmt.Printf("Status of the machine %s\n", status.Hostname) + needToReboot := "no" + if status.NeedToReboot { + needToReboot = "yes" + } + fmt.Printf(" Need to reboot: %s\n", needToReboot) for _, r := range status.RepositoryStatus.Remotes { fmt.Printf(" Remote %s fetched %s\n", r.Url, humanize.Time(r.FetchedAt), diff --git a/internal/manager/manager.go b/internal/manager/manager.go index ca890e7..e3f7d34 100644 --- a/internal/manager/manager.go +++ b/internal/manager/manager.go @@ -22,6 +22,7 @@ type State struct { IsRunning bool `json:"is_running"` Deployment deployment.Deployment `json:"deployment"` Hostname string `json:"hostname"` + NeedToReboot bool `json:"need_to_reboot"` } type Manager struct {