Documentation ¶
Index ¶
Constants ¶
View Source
const ( DefaultRamSize = 1 * 1024 // 1GB MinRamSize = 32 // 32MB MaxRamSize = 32 * 1024 // 32GB MinNestedVirtualizationRamSize = 4 * 1024 // 4GB LowRam = 256 // 256MB DefaultUsername = "" DefaultPassword = "" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Builder ¶
type Builder struct {
// contains filtered or unexported fields
}
Builder implements packer.Builder and builds the actual Hyperv images.
type Config ¶
type Config struct { common.PackerConfig `mapstructure:",squash"` common.HTTPConfig `mapstructure:",squash"` common.ISOConfig `mapstructure:",squash"` common.FloppyConfig `mapstructure:",squash"` hypervcommon.OutputConfig `mapstructure:",squash"` hypervcommon.SSHConfig `mapstructure:",squash"` hypervcommon.RunConfig `mapstructure:",squash"` hypervcommon.ShutdownConfig `mapstructure:",squash"` // The size, in megabytes, of the computer memory in the VM. // By default, this is 1024 (about 1 GB). RamSize uint `mapstructure:"ram_size"` // SecondaryDvdImages []string `mapstructure:"secondary_iso_images"` // Should integration services iso be mounted GuestAdditionsMode string `mapstructure:"guest_additions_mode"` // The path to the integration services iso GuestAdditionsPath string `mapstructure:"guest_additions_path"` // This is the path to a directory containing an exported virtual machine. CloneFromVMXCPath string `mapstructure:"clone_from_vmxc_path"` // This is the name of the virtual machine to clone from. CloneFromVMName string `mapstructure:"clone_from_vm_name"` // This is the name of the snapshot to clone from. A blank snapshot name will use the latest snapshot. CloneFromSnapshotName string `mapstructure:"clone_from_snapshot_name"` // This will clone all snapshots if true. It will clone latest snapshot if false. CloneAllSnapshots bool `mapstructure:"clone_all_snapshots"` // This is the name of the new virtual machine. // By default this is "packer-BUILDNAME", where "BUILDNAME" is the name of the build. VMName string `mapstructure:"vm_name"` // Use differencing disk DifferencingDisk bool `mapstructure:"differencing_disk"` BootCommand []string `mapstructure:"boot_command"` SwitchName string `mapstructure:"switch_name"` SwitchVlanId string `mapstructure:"switch_vlan_id"` MacAddress string `mapstructure:"mac_address"` VlanId string `mapstructure:"vlan_id"` Cpu uint `mapstructure:"cpu"` Generation uint EnableMacSpoofing bool `mapstructure:"enable_mac_spoofing"` EnableDynamicMemory bool `mapstructure:"enable_dynamic_memory"` EnableSecureBoot bool `mapstructure:"enable_secure_boot"` EnableVirtualizationExtensions bool `mapstructure:"enable_virtualization_extensions"` Communicator string `mapstructure:"communicator"` SkipCompaction bool `mapstructure:"skip_compaction"` SkipExport bool `mapstructure:"skip_export"` // contains filtered or unexported fields }
Click to show internal directories.
Click to hide internal directories.