diff --git a/communicator/ssh/communicator.go b/communicator/ssh/communicator.go index c8534c16da4b..ff01aa3f9653 100644 --- a/communicator/ssh/communicator.go +++ b/communicator/ssh/communicator.go @@ -230,7 +230,7 @@ func (c *Communicator) UploadScript(path string, input io.Reader) error { } cmd := &remote.Cmd{ - Command: fmt.Sprintf("chmod 0777 %s", c.connInfo.ScriptPath), + Command: fmt.Sprintf("chmod 0777 %s", fmt.Sprint(path, script)), } if err := c.Start(cmd); err != nil { return fmt.Errorf(