Merge pull request #113 from ehazlett/ec2-fixes

add standard upgrade procedure; spelling
This commit is contained in:
Ben Firshman 2014-12-18 01:50:49 +00:00
commit eabb103f8b
1 changed files with 9 additions and 2 deletions

View File

@ -320,7 +320,7 @@ func (d *Driver) Stop() error {
func (d *Driver) Remove() error {
if err := d.terminate(); err != nil {
return fmt.Errorf("unabme to terminate instance: %s", err)
return fmt.Errorf("unable to terminate instance: %s", err)
}
// wait until terminated so we can remove security group
for {
@ -361,7 +361,14 @@ func (d *Driver) Kill() error {
}
func (d *Driver) Upgrade() error {
return fmt.Errorf("unable to upgrade as we are using the custom docker binary with identity auth")
sshCmd, err := d.GetSSHCommand("apt-get update && apt-get install -y lxc-docker")
if err != nil {
return err
}
sshCmd.Stdin = os.Stdin
sshCmd.Stdout = os.Stdout
sshCmd.Stderr = os.Stderr
return sshCmd.Run()
}
func (d *Driver) GetSSHCommand(args ...string) (*exec.Cmd, error) {