fmt
This commit is contained in:
parent
81d8cd0db4
commit
e422a45449
|
@ -125,7 +125,7 @@ func WaitForState(conf *StateChangeConf) (i interface{}, err error) {
|
||||||
log.Printf("Waiting for state to become: %s", conf.Target)
|
log.Printf("Waiting for state to become: %s", conf.Target)
|
||||||
|
|
||||||
sleepSeconds := 2
|
sleepSeconds := 2
|
||||||
maxTicks := int(TimeoutSeconds() / sleepSeconds) + 1
|
maxTicks := int(TimeoutSeconds()/sleepSeconds) + 1
|
||||||
notfoundTick := 0
|
notfoundTick := 0
|
||||||
|
|
||||||
for {
|
for {
|
||||||
|
|
|
@ -58,11 +58,11 @@ func (s *StepCreateInstance) Run(state multistep.StateBag) multistep.StepAction
|
||||||
DiskSizeGb: config.DiskSizeGb,
|
DiskSizeGb: config.DiskSizeGb,
|
||||||
Image: config.getImage(),
|
Image: config.getImage(),
|
||||||
MachineType: config.MachineType,
|
MachineType: config.MachineType,
|
||||||
Metadata: config.getInstanceMetadata(sshPublicKey),
|
Metadata: config.getInstanceMetadata(sshPublicKey),
|
||||||
Name: name,
|
Name: name,
|
||||||
Network: config.Network,
|
Network: config.Network,
|
||||||
Tags: config.Tags,
|
Tags: config.Tags,
|
||||||
Zone: config.Zone,
|
Zone: config.Zone,
|
||||||
})
|
})
|
||||||
|
|
||||||
if err == nil {
|
if err == nil {
|
||||||
|
|
|
@ -26,7 +26,7 @@ func (d *Fusion6Driver) Clone(dst, src string) error {
|
||||||
if _, _, err := runAndLog(cmd); err != nil {
|
if _, _, err := runAndLog(cmd); err != nil {
|
||||||
if strings.Contains(err.Error(), "parameters was invalid") {
|
if strings.Contains(err.Error(), "parameters was invalid") {
|
||||||
return fmt.Errorf(
|
return fmt.Errorf(
|
||||||
"Clone is not supported with your version of Fusion. Packer " +
|
"Clone is not supported with your version of Fusion. Packer "+
|
||||||
"only works with Fusion %s Professional or above. Please verify your version.", VMWARE_FUSION_VERSION)
|
"only works with Fusion %s Professional or above. Please verify your version.", VMWARE_FUSION_VERSION)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -22,11 +22,11 @@ import (
|
||||||
// ESX5 driver talks to an ESXi5 hypervisor remotely over SSH to build
|
// ESX5 driver talks to an ESXi5 hypervisor remotely over SSH to build
|
||||||
// virtual machines. This driver can only manage one machine at a time.
|
// virtual machines. This driver can only manage one machine at a time.
|
||||||
type ESX5Driver struct {
|
type ESX5Driver struct {
|
||||||
Host string
|
Host string
|
||||||
Port uint
|
Port uint
|
||||||
Username string
|
Username string
|
||||||
Password string
|
Password string
|
||||||
Datastore string
|
Datastore string
|
||||||
CacheDatastore string
|
CacheDatastore string
|
||||||
CacheDirectory string
|
CacheDirectory string
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package rpc
|
package rpc
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/hashicorp/go-msgpack/codec"
|
"github.com/hashicorp/go-msgpack/codec"
|
||||||
|
"github.com/mitchellh/packer/packer"
|
||||||
"io"
|
"io"
|
||||||
"log"
|
"log"
|
||||||
"net/rpc"
|
"net/rpc"
|
||||||
|
|
|
@ -2,8 +2,8 @@ package rpc
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/hashicorp/go-msgpack/codec"
|
"github.com/hashicorp/go-msgpack/codec"
|
||||||
|
"github.com/mitchellh/packer/packer"
|
||||||
"io"
|
"io"
|
||||||
"log"
|
"log"
|
||||||
"net/rpc"
|
"net/rpc"
|
||||||
|
|
|
@ -111,7 +111,7 @@ func (p *PostProcessor) PostProcess(ui packer.Ui, artifact packer.Artifact) (pac
|
||||||
// The name of the provider for vagrant cloud, and vagrant
|
// The name of the provider for vagrant cloud, and vagrant
|
||||||
providerName := providerFromBuilderName(artifact.Id())
|
providerName := providerFromBuilderName(artifact.Id())
|
||||||
|
|
||||||
boxDownloadUrl, err := p.config.tpl.Process(p.config.BoxDownloadUrl, &boxDownloadUrlTemplate {
|
boxDownloadUrl, err := p.config.tpl.Process(p.config.BoxDownloadUrl, &boxDownloadUrlTemplate{
|
||||||
ArtifactId: artifact.Id(),
|
ArtifactId: artifact.Id(),
|
||||||
Provider: providerName,
|
Provider: providerName,
|
||||||
})
|
})
|
||||||
|
|
|
@ -2,9 +2,9 @@ package vagrantcloud
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"strings"
|
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/mitchellh/packer/packer"
|
||||||
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
||||||
type stepReleaseVersion struct {
|
type stepReleaseVersion struct {
|
||||||
|
|
Loading…
Reference in New Issue