| 295 continue |
295 continue |
| 296 } |
296 } |
| 297 |
297 |
| 298 // run build.sh |
298 // run build.sh |
| 299 build_dir := "build" |
299 build_dir := "build" |
| 300 remote_command := fmt.Sprintf("sh -c 'rm -Rf %s; mkdir -p %s; gzip -dc build.tar.gz | tar xf - -C %s ; (cd %s; ./build.sh)'", build_dir, build_dir, build_dir, build_dir) |
300 remote_command := fmt.Sprintf("sh -c 'rm -Rf %[1]s; mkdir -p %[1]s; gzip -dc build.tar.gz | tar xf - -C %[1]s ; (cd %[1]s; ./build.sh)'", build_dir) |
| 301 log.Printf("host: %s: command: %s", env.Host, remote_command) |
301 log.Printf("host: %s: command: %s", env.Host, remote_command) |
| 302 |
302 |
| 303 var outb, errb bytes.Buffer |
303 var outb, errb bytes.Buffer |
| 304 cmd = exec.Command("ssh", "-t", env.Host, remote_command) |
304 cmd = exec.Command("ssh", "-t", env.Host, remote_command) |
| 305 cmd.Stdout = &outb |
305 cmd.Stdout = &outb |