summaryrefslogtreecommitdiff
path: root/poll.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2024-10-15 11:02:34 -0500
committerJeff Carr <[email protected]>2024-10-15 11:02:34 -0500
commit1c77ec7e63355cab48564a9fb49f34f55b5f0b15 (patch)
tree8d081863ea226465827f9d266b0e701da216220e /poll.go
parentaa6b142b7c156b8f1925eb4af10b0b371263a129 (diff)
start from the command line works
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'poll.go')
-rw-r--r--poll.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/poll.go b/poll.go
index 1497509..bc3ea49 100644
--- a/poll.go
+++ b/poll.go
@@ -87,6 +87,7 @@ func clusterHealthy() (bool, string) {
var failed int
var missing int
var unknown int
+ var unknownList []string
for _, d := range me.droplets {
total += 1
@@ -97,6 +98,7 @@ func clusterHealthy() (bool, string) {
if d.CurrentState == "" {
// log.Info("SKIP. hostname has not been polled yet", d.Hostname, d.hname)
unknown += 1
+ unknownList = append(unknownList, d.Hostname)
continue
}
if d.CurrentState != "ON" {
@@ -129,7 +131,7 @@ func clusterHealthy() (bool, string) {
summary += fmt.Sprintf("missing = %d ", missing)
}
if unknown > 0 {
- summary += fmt.Sprintf("unknown = %d ", unknown)
+ summary += fmt.Sprintf("unknown = %d ", unknown, unknownList)
}
if failed > 0 {
summary += fmt.Sprintf("failed = %d ", failed)