@@ -15,6 +15,7 @@ import (
1515 "math/rand"
1616 "net/http"
1717 "os"
18+ "strings"
1819 "text/tabwriter"
1920 "time"
2021)
@@ -104,16 +105,16 @@ func (c *Client) updateservice() {
104105 fmt .Println ("starting systemd units" )
105106 files , _ := utils .ListFiles (downloadDir + "*.service" )
106107 fmt .Println (files )
107- deis , err := client .NewClient ()
108+ deis , _ := client .NewClient ()
108109 localServices := deis .GetLocaljobs ()
109110 Services := utils .GetServices ()
110- if len ( localService ) == 0 {
111+ if localServices . Len ( ) == 0 {
111112 fmt .Println ("no local services" )
112113 return
113114 }
114115 for _ , service := range localServices {
115- cmd .Unisntall (deis , strings .Split (strings .Split (service , "-" )[1 ], "." )[0 ])
116- cmd .Install (deis , strings .Split (strings .Split (service , "-" )[1 ], "." )[0 ])
116+ cmd .Uninstall (deis , [] string { strings .Split (strings .Split (service , "-" )[1 ], "." )[0 ]} )
117+ cmd .Install (deis , [] string { strings .Split (strings .Split (service , "-" )[1 ], "." )[0 ]} )
117118 }
118119 var count int
119120 for _ , service := range Services {
@@ -125,7 +126,7 @@ func (c *Client) updateservice() {
125126 }
126127 if count == 0 {
127128 go func () {
128- cmd .PullImage (service )
129+ _ = cmd .PullImage (service )
129130 }()
130131 }
131132 }
0 commit comments