mirror of
https://github.com/docker/docs.git
synced 2026-11-06 12:54:24 +03:00
save IP to vmwarefusion config; google driver cleanup
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
This commit is contained in:
@@ -9,7 +9,6 @@ import (
|
||||
"time"
|
||||
|
||||
log "github.com/Sirupsen/logrus"
|
||||
"github.com/docker/machine/drivers"
|
||||
"github.com/docker/machine/ssh"
|
||||
raw "google.golang.org/api/compute/v1"
|
||||
)
|
||||
@@ -254,9 +253,6 @@ func (c *ComputeUtil) updateDocker(d *Driver) error {
|
||||
if err := c.executeCommands(commands, ip, d.sshKeyPath); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := drivers.AddPublicKeyToAuthorizedHosts(d, "/.docker/authorized-keys.d"); err != nil {
|
||||
return err
|
||||
}
|
||||
return c.executeCommands([]string{dockerStartCommand}, ip, d.sshKeyPath)
|
||||
}
|
||||
|
||||
|
||||
@@ -36,6 +36,7 @@ const (
|
||||
// Driver for VMware Fusion
|
||||
type Driver struct {
|
||||
MachineName string
|
||||
IPAddress string
|
||||
Memory int
|
||||
DiskSize int
|
||||
ISO string
|
||||
@@ -233,6 +234,8 @@ func (d *Driver) Create() error {
|
||||
return fmt.Errorf("Machine didn't return an IP after 120 seconds, aborting")
|
||||
}
|
||||
|
||||
d.IPAddress = ip
|
||||
|
||||
key, err := ioutil.ReadFile(d.publicSSHKeyPath())
|
||||
if err != nil {
|
||||
return err
|
||||
|
||||
Reference in New Issue
Block a user