github.com/hashicorp/packer@v1.14.3/examples/hcl/linux/source.esxi-vmware-iso.pkr.hcl (about)

     1  source "vmware-iso" "esxi-base-ubuntu-amd64" {
     2      headless                = var.headless
     3      boot_wait               = "10s"
     4      guest_os_type           = "ubuntu-64"
     5      http_directory          = local.http_directory
     6      shutdown_command        = "echo 'vagrant' | sudo -S shutdown -P now"
     7      ssh_password            = "vagrant"
     8      ssh_port                = 22
     9      ssh_timeout             = "10000s"
    10      ssh_username            = "vagrant"
    11      tools_upload_flavor     = "linux"
    12      vmx_data = {
    13          "cpuid.coresPerSocket" = "1"
    14          "ethernet0.pciSlotNumber" = "32"
    15      }
    16      vmx_remove_ethernet_interfaces = true
    17  
    18      remote_type             = "esx5"
    19      remote_host             = var.esxi_host
    20      remote_username         = var.esxi_user
    21      remote_password         = var.esxi_password
    22      remote_datastore        = var.datastore
    23      remote_private_key_file = var.remote_private_key_file_path
    24  }
    25  
    26  source "vmware-iso" "esxi-base-alpine-amd64" {
    27      headless                = var.headless
    28      boot_wait               = "10s"
    29      guest_os_type           = "otherLinux64Guest"
    30      floppy_files            = local.floppy_files_alpine_vsphere
    31      ssh_port                = 22
    32      ssh_timeout             = "10000s"
    33      ssh_username            = "root"
    34      ssh_password            = var.alpine_password
    35      tools_upload_flavor     = "linux"
    36      shutdown_command        = "poweroff"
    37      vmx_data = {
    38          "cpuid.coresPerSocket" = "1"
    39          "ethernet0.pciSlotNumber" = "32"
    40      }
    41      vmx_remove_ethernet_interfaces = true
    42  
    43      remote_type             = "esx5"
    44      remote_host             = var.esxi_host
    45      remote_username         = var.esxi_user
    46      remote_password         = var.esxi_password
    47      remote_datastore        = var.datastore
    48      remote_private_key_file = var.remote_private_key_file_path
    49  }