summaryrefslogtreecommitdiff
path: root/http.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2024-10-27 04:53:39 -0500
committerJeff Carr <[email protected]>2024-10-27 04:53:39 -0500
commit212b582060107d8e64ca9dbe8e194cc922e460fa (patch)
tree00948d77892ca8ec5aa65a4754d0f9b0fda3853b /http.go
parentd948581300ecea1b5407662be9e812ddf237e6cf (diff)
sets unique spice port and saves config filesv0.2
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'http.go')
-rw-r--r--http.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/http.go b/http.go
index 51c5a10..629b973 100644
--- a/http.go
+++ b/http.go
@@ -99,11 +99,13 @@ func okHandler(w http.ResponseWriter, r *http.Request) {
fmt.Fprintln(w, "hostname is", hostname)
// log.Warn("Handling URL:", tmp, "start droplet", start)
- ok, result := Start(hostname)
- if ok {
+ result, err := Start(hostname)
+ if err == nil {
+ fmt.Fprintln(w, result)
fmt.Fprintln(w, hostname, "started ok")
} else {
fmt.Fprintln(w, result)
+ fmt.Fprintln(w, err)
fmt.Fprintln(w, hostname, "start failed")
}
return