Versions in this module Expand all Collapse all v1 v1.3.2 Oct 29, 2018 Changes in this version + const ALLOW + const BuilderId + const DENY + const IGNORE + const NetworkingInterfacePrefix + const NetworkingType_BRIDGED + const NetworkingType_HOSTONLY + const NetworkingType_NAT + const VMWARE_FUSION_VERSION + const VMWARE_PLAYER_VERSION + const VMWARE_WS_VERSION + var KeepFileExtensions = []string + var NetworkingCommandParsers = []networkingCommandParser + func CommHost(config *SSHConfig) func(multistep.StateBag) (string, error) + func EncodeVMX(contents map[string]string) string + func MockInterface() net.Interface + func NetworkingParserByCommand(command string) *func([]string) (*networkingCommandEntry, error) + func NewLocalArtifact(id string, dir string) (packer.Artifact, error) + func ParseVMX(contents string) map[string]string + func ReadVMX(path string) (map[string]string, error) + func VNCPassword(skipPassword bool) string + func WriteVMX(path string, data map[string]string) (err error) + type DhcpConfiguration []configDeclaration + func ReadDhcpConfig(path string) (DhcpConfiguration, error) + func ReadDhcpConfiguration(fd *os.File) (DhcpConfiguration, error) + func (e *DhcpConfiguration) Global() configDeclaration + func (e *DhcpConfiguration) HostByName(host string) (configDeclaration, error) + func (e *DhcpConfiguration) SubnetByAddress(address net.IP) (configDeclaration, error) + type Driver interface + Clone func(dst string, src string, cloneType bool) error + CommHost func(multistep.StateBag) (string, error) + CompactDisk func(string) error + CreateDisk func(string, string, string, string) error + GetVmwareDriver func() VmwareDriver + GuestAddress func(multistep.StateBag) (string, error) + GuestIP func(multistep.StateBag) (string, error) + HostAddress func(multistep.StateBag) (string, error) + HostIP func(multistep.StateBag) (string, error) + IsRunning func(string) (bool, error) + Start func(string, bool) error + Stop func(string) error + SuppressMessages func(string) error + ToolsInstall func() error + ToolsIsoPath func(string) string + Verify func() error + func NewDriver(dconfig *DriverConfig, config *SSHConfig) (Driver, error) + type DriverConfig struct + FusionAppPath string + func (c *DriverConfig) Prepare(ctx *interpolate.Context) []error + type DriverMock struct + CloneCalled bool + CloneDst string + CloneErr error + CloneSrc string + CommHostCalled bool + CommHostErr error + CommHostResult string + CommHostState multistep.StateBag + CompactDiskCalled bool + CompactDiskErr error + CompactDiskPath string + CreateDiskAdapterType string + CreateDiskCalled bool + CreateDiskErr error + CreateDiskOutput string + CreateDiskSize string + CreateDiskTypeId string + DhcpConfPathCalled bool + DhcpConfPathResult string + DhcpLeasesPathCalled bool + DhcpLeasesPathDevice string + DhcpLeasesPathResult string + GuestAddressCalled bool + GuestAddressErr error + GuestAddressResult string + GuestAddressState multistep.StateBag + GuestIPCalled bool + GuestIPErr error + GuestIPResult string + GuestIPState multistep.StateBag + HostAddressCalled bool + HostAddressErr error + HostAddressResult string + HostAddressState multistep.StateBag + HostIPCalled bool + HostIPErr error + HostIPResult string + HostIPState multistep.StateBag + IsRunningCalled bool + IsRunningErr error + IsRunningPath string + IsRunningResult bool + Linked bool + NetmapConfPathCalled bool + NetmapConfPathResult string + StartCalled bool + StartErr error + StartHeadless bool + StartPath string + StopCalled bool + StopErr error + StopPath string + SuppressMessagesCalled bool + SuppressMessagesErr error + SuppressMessagesPath string + ToolsInstallCalled bool + ToolsInstallErr error + ToolsIsoPathCalled bool + ToolsIsoPathFlavor string + ToolsIsoPathResult string + VerifyCalled bool + VerifyErr error + VmnetnatConfPathCalled bool + VmnetnatConfPathResult string + func (d *DriverMock) Clone(dst string, src string, linked bool) error + func (d *DriverMock) CommHost(state multistep.StateBag) (string, error) + func (d *DriverMock) CompactDisk(path string) error + func (d *DriverMock) CreateDisk(output string, size string, adapterType string, typeId string) error + func (d *DriverMock) DhcpConfPath(device string) string + func (d *DriverMock) DhcpLeasesPath(device string) string + func (d *DriverMock) GetVmwareDriver() VmwareDriver + func (d *DriverMock) GuestAddress(state multistep.StateBag) (string, error) + func (d *DriverMock) GuestIP(state multistep.StateBag) (string, error) + func (d *DriverMock) HostAddress(state multistep.StateBag) (string, error) + func (d *DriverMock) HostIP(state multistep.StateBag) (string, error) + func (d *DriverMock) IsRunning(path string) (bool, error) + func (d *DriverMock) NetmapConfPath() string + func (d *DriverMock) Start(path string, headless bool) error + func (d *DriverMock) Stop(path string) error + func (d *DriverMock) SuppressMessages(path string) error + func (d *DriverMock) ToolsInstall() error + func (d *DriverMock) ToolsIsoPath(flavor string) string + func (d *DriverMock) Verify() error + func (d *DriverMock) VmnetnatConfPath(device string) string + type Fusion5Driver struct + AppPath string + SSHConfig *SSHConfig + func (d *Fusion5Driver) Clone(dst, src string, linked bool) error + func (d *Fusion5Driver) CommHost(state multistep.StateBag) (string, error) + func (d *Fusion5Driver) CompactDisk(diskPath string) error + func (d *Fusion5Driver) CreateDisk(output string, size string, adapter_type string, type_id string) error + func (d *Fusion5Driver) GetVmwareDriver() VmwareDriver + func (d *Fusion5Driver) IsRunning(vmxPath string) (bool, error) + func (d *Fusion5Driver) Start(vmxPath string, headless bool) error + func (d *Fusion5Driver) Stop(vmxPath string) error + func (d *Fusion5Driver) SuppressMessages(vmxPath string) error + func (d *Fusion5Driver) ToolsInstall() error + func (d *Fusion5Driver) ToolsIsoPath(k string) string + func (d *Fusion5Driver) Verify() error + type Fusion6Driver struct + func (d *Fusion6Driver) Clone(dst, src string, linked bool) error + func (d *Fusion6Driver) GetVmwareDriver() VmwareDriver + func (d *Fusion6Driver) Verify() error + type IfconfigIPFinder struct + Device string + func (f *IfconfigIPFinder) HostIP() (string, error) + type LocalOutputDir struct + func (d *LocalOutputDir) DirExists() (bool, error) + func (d *LocalOutputDir) ListFiles() ([]string, error) + func (d *LocalOutputDir) MkdirAll() error + func (d *LocalOutputDir) Remove(path string) error + func (d *LocalOutputDir) RemoveAll() error + func (d *LocalOutputDir) SetOutputDir(path string) + func (d *LocalOutputDir) String() string + type NetworkMap []map[string]string + func ReadNetmapConfig(path string) (NetworkMap, error) + func ReadNetworkMap(fd *os.File) (NetworkMap, error) + func (e NetworkMap) DeviceIntoName(device string) (string, error) + func (e NetworkMap) NameIntoDevices(name string) ([]string, error) + type NetworkMapperMock struct + DeviceIntoNameCalled int + NameIntoDeviceCalled int + func (m NetworkMapperMock) DeviceIntoName(device string) (string, error) + func (m NetworkMapperMock) NameIntoDevices(name string) ([]string, error) + type NetworkNameMapper interface + DeviceIntoName func(string) (string, error) + NameIntoDevices func(string) ([]string, error) + type NetworkingConfig struct + func ReadNetworkingConfig(fd *os.File) (NetworkingConfig, error) + func (e NetworkingConfig) DeviceIntoName(device string) (string, error) + func (e NetworkingConfig) NameIntoDevices(name string) ([]string, error) + type NetworkingType int + type OutputConfig struct + OutputDir string + func (c *OutputConfig) Prepare(ctx *interpolate.Context, pc *common.PackerConfig) []error + type OutputDir interface + DirExists func() (bool, error) + ListFiles func() ([]string, error) + MkdirAll func() error + Remove func(string) error + RemoveAll func() error + SetOutputDir func(string) + String func() string + type Player5Driver struct + AppPath string + QemuImgPath string + SSHConfig *SSHConfig + VdiskManagerPath string + VmrunPath string + func (d *Player5Driver) Clone(dst, src string, linked bool) error + func (d *Player5Driver) CommHost(state multistep.StateBag) (string, error) + func (d *Player5Driver) CompactDisk(diskPath string) error + func (d *Player5Driver) CreateDisk(output string, size string, adapter_type string, type_id string) error + func (d *Player5Driver) GetVmwareDriver() VmwareDriver + func (d *Player5Driver) IsRunning(vmxPath string) (bool, error) + func (d *Player5Driver) Start(vmxPath string, headless bool) error + func (d *Player5Driver) Stop(vmxPath string) error + func (d *Player5Driver) SuppressMessages(vmxPath string) error + func (d *Player5Driver) ToolsInstall() error + func (d *Player5Driver) ToolsIsoPath(flavor string) string + func (d *Player5Driver) Verify() error + type Player6Driver struct + func (d *Player6Driver) Clone(dst, src string, linked bool) error + func (d *Player6Driver) GetVmwareDriver() VmwareDriver + func (d *Player6Driver) Verify() error + type RunConfig struct + Headless bool + VNCBindAddress string + VNCDisablePassword bool + VNCPortMax uint + VNCPortMin uint + func (c *RunConfig) Prepare(ctx *interpolate.Context) (errs []error) + type SSHConfig struct + Comm communicator.Config + SSHSkipRequestPty bool + SSHWaitTimeout time.Duration + func (c *SSHConfig) Prepare(ctx *interpolate.Context) []error + type ShutdownConfig struct + RawShutdownTimeout string + ShutdownCommand string + ShutdownTimeout time.Duration + func (c *ShutdownConfig) Prepare(ctx *interpolate.Context) []error + type StepCleanFiles struct + func (StepCleanFiles) Cleanup(multistep.StateBag) + func (StepCleanFiles) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepCleanVMX struct + RemoveEthernetInterfaces bool + VNCEnabled bool + func (StepCleanVMX) Cleanup(multistep.StateBag) + func (s StepCleanVMX) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepCompactDisk struct + Skip bool + func (StepCompactDisk) Cleanup(multistep.StateBag) + func (s StepCompactDisk) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepConfigureVMX struct + CustomData map[string]string + SkipFloppy bool + func (s *StepConfigureVMX) Cleanup(state multistep.StateBag) + func (s *StepConfigureVMX) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepConfigureVNC struct + Enabled bool + VNCBindAddress string + VNCDisablePassword bool + VNCPortMax uint + VNCPortMin uint + func (StepConfigureVNC) Cleanup(multistep.StateBag) + func (StepConfigureVNC) UpdateVMX(address, password string, port uint, data map[string]string) + func (StepConfigureVNC) VNCAddress(vncBindAddress string, portMin, portMax uint) (string, uint, error) + func (s *StepConfigureVNC) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepOutputDir struct + Force bool + func (s *StepOutputDir) Cleanup(state multistep.StateBag) + func (s *StepOutputDir) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepPrepareTools struct + RemoteType string + ToolsUploadFlavor string + func (c *StepPrepareTools) Cleanup(multistep.StateBag) + func (c *StepPrepareTools) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepRun struct + DurationBeforeStop time.Duration + Headless bool + func (s *StepRun) Cleanup(state multistep.StateBag) + func (s *StepRun) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepShutdown struct + Command string + Testing bool + Timeout time.Duration + func (s *StepShutdown) Cleanup(state multistep.StateBag) + func (s *StepShutdown) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepSuppressMessages struct + func (s *StepSuppressMessages) Cleanup(state multistep.StateBag) + func (s *StepSuppressMessages) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type StepTypeBootCommand struct + BootCommand string + BootWait time.Duration + Ctx interpolate.Context + KeyInterval time.Duration + VMName string + VNCEnabled bool + func (*StepTypeBootCommand) Cleanup(multistep.StateBag) + func (s *StepTypeBootCommand) Run(ctx context.Context, state multistep.StateBag) multistep.StepAction + type StepUploadTools struct + Ctx interpolate.Context + RemoteType string + ToolsUploadFlavor string + ToolsUploadPath string + func (c *StepUploadTools) Cleanup(multistep.StateBag) + func (c *StepUploadTools) Run(_ context.Context, state multistep.StateBag) multistep.StepAction + type ToolsConfig struct + ToolsUploadFlavor string + ToolsUploadPath string + func (c *ToolsConfig) Prepare(ctx *interpolate.Context) []error + type VMXConfig struct + VMXData map[string]string + VMXDataPost map[string]string + VMXRemoveEthernet bool + func (c *VMXConfig) Prepare(ctx *interpolate.Context) []error + type VNCAddressFinder interface + UpdateVMX func(vncAddress, vncPassword string, vncPort uint, vmxData map[string]string) + VNCAddress func(string, uint, uint) (string, uint, error) + type VmwareDriver struct + DhcpConfPath func(string) string + DhcpLeasesPath func(string) string + NetworkMapper func() (NetworkNameMapper, error) + VmnetnatConfPath func(string) string + func (d *VmwareDriver) GuestAddress(state multistep.StateBag) (string, error) + func (d *VmwareDriver) GuestIP(state multistep.StateBag) (string, error) + func (d *VmwareDriver) HostAddress(state multistep.StateBag) (string, error) + func (d *VmwareDriver) HostIP(state multistep.StateBag) (string, error) + type Workstation10Driver struct + func (d *Workstation10Driver) Clone(dst, src string, linked bool) error + func (d *Workstation10Driver) GetVmwareDriver() VmwareDriver + func (d *Workstation10Driver) Verify() error + type Workstation9Driver struct + AppPath string + SSHConfig *SSHConfig + VdiskManagerPath string + VmrunPath string + func (d *Workstation9Driver) Clone(dst, src string, linked bool) error + func (d *Workstation9Driver) CommHost(state multistep.StateBag) (string, error) + func (d *Workstation9Driver) CompactDisk(diskPath string) error + func (d *Workstation9Driver) CreateDisk(output string, size string, adapter_type string, type_id string) error + func (d *Workstation9Driver) GetVmwareDriver() VmwareDriver + func (d *Workstation9Driver) IsRunning(vmxPath string) (bool, error) + func (d *Workstation9Driver) Start(vmxPath string, headless bool) error + func (d *Workstation9Driver) Stop(vmxPath string) error + func (d *Workstation9Driver) SuppressMessages(vmxPath string) error + func (d *Workstation9Driver) ToolsInstall() error + func (d *Workstation9Driver) ToolsIsoPath(flavor string) string + func (d *Workstation9Driver) Verify() error