diff options
| author | Jeff Carr <[email protected]> | 2024-10-12 10:59:11 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-10-12 10:59:11 -0500 |
| commit | d08d9f99bee4d4e93a8beda780d8e9f6099e32cb (patch) | |
| tree | 78540be4d3b371569f59ee863621b03786a479c5 /http.go | |
| parent | 0751e80559cbb34bc23639328938780c64063c92 (diff) | |
ugly but limping along progress
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'http.go')
| -rw-r--r-- | http.go | 21 |
1 files changed, 2 insertions, 19 deletions
@@ -5,7 +5,6 @@ import ( "net/http" "strings" - "go.wit.com/lib/gui/shell" "go.wit.com/log" ) @@ -30,24 +29,8 @@ func okHandler(w http.ResponseWriter, r *http.Request) { } if tmp == "/vms" { - for _, hostname := range argv.Hosts { - url := "http://" + hostname + ":2520/vms" - log.Info("wget url =", url) - s := shell.Wget(url) - if s == nil { - continue; - } - var bytesSplice []byte - bytesSplice = s.Bytes() - // fmt.Fprintln(w, string(bytesSplice)) - for _, line := range strings.Split(string(bytesSplice), "\n") { - if line == "" { - continue - } - fmt.Fprintln(w, hostname, line) - log.Info("LINE: =", hostname, line) - } - // log.Info("i, s =", hostname, i, s) + for _, d := range me.droplets { + fmt.Fprintln(w, d.Hostname, d.hname, d.lastpoll) } return } |
