Here is the full log output, slightly edited for privacy:
2021/02/16 09:00:38 [INFO] Packer version: 1.6.6 [go1.15.5 darwin amd64]
2021/02/16 09:00:38 Checking 'PACKER_CONFIG' for a config file path
2021/02/16 09:00:38 'PACKER_CONFIG' not set; checking the default config file path
2021/02/16 09:00:38 Attempting to open config file: /Users/USER/.packerconfig
2021/02/16 09:00:38 [WARN] Config file doesn't exist: /Users/USER/.packerconfig
2021/02/16 09:00:38 Setting cache directory: /Users/USER/packer_cache
2021/02/16 09:00:38 Creating plugin client for path: /usr/local/bin/packer
2021/02/16 09:00:38 Starting plugin: /usr/local/bin/packer []string{"/usr/local/bin/packer", "plugin", "packer-builder-vsphere-iso"}
2021/02/16 09:00:38 Waiting for RPC address for: /usr/local/bin/packer
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: [INFO] Packer version: 1.6.6 [go1.15.5 darwin amd64]
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: Checking 'PACKER_CONFIG' for a config file path
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: 'PACKER_CONFIG' not set; checking the default config file path
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: Attempting to open config file: /Users/USER/.packerconfig
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: [WARN] Config file doesn't exist: /Users/USER/.packerconfig
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: Setting cache directory: /Users/USER/packer_cache
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: args: []string{"packer-builder-vsphere-iso"}
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: Plugin address: unix /var/folders/kw/ljks13q92xg2d5chv2zy5km80000gp/T/packer-plugin861829774
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: Waiting for connection...
2021/02/16 09:00:38 Received unix RPC address for /usr/local/bin/packer: addr is /var/folders/kw/ljks13q92xg2d5chv2zy5km80000gp/T/packer-plugin861829774
2021/02/16 09:00:38 packer-builder-vsphere-iso plugin: Serving a plugin connection...
2021/02/16 09:00:38 Creating plugin client for path: /usr/local/bin/packer
2021/02/16 09:00:38 Starting plugin: /usr/local/bin/packer []string{"/usr/local/bin/packer", "plugin", "packer-provisioner-shell"}
2021/02/16 09:00:38 Waiting for RPC address for: /usr/local/bin/packer
2021/02/16 09:00:38 packer-provisioner-shell plugin: [INFO] Packer version: 1.6.6 [go1.15.5 darwin amd64]
2021/02/16 09:00:38 packer-provisioner-shell plugin: Checking 'PACKER_CONFIG' for a config file path
2021/02/16 09:00:38 packer-provisioner-shell plugin: 'PACKER_CONFIG' not set; checking the default config file path
2021/02/16 09:00:38 packer-provisioner-shell plugin: Attempting to open config file: /Users/USER/.packerconfig
2021/02/16 09:00:38 packer-provisioner-shell plugin: [WARN] Config file doesn't exist: /Users/USER/.packerconfig
2021/02/16 09:00:38 packer-provisioner-shell plugin: Setting cache directory: /Users/USER/packer_cache
2021/02/16 09:00:38 packer-provisioner-shell plugin: args: []string{"packer-provisioner-shell"}
2021/02/16 09:00:38 Received unix RPC address for /usr/local/bin/packer: addr is /var/folders/kw/ljks13q92xg2d5chv2zy5km80000gp/T/packer-plugin178538386
2021/02/16 09:00:38 packer-provisioner-shell plugin: Plugin address: unix /var/folders/kw/ljks13q92xg2d5chv2zy5km80000gp/T/packer-plugin178538386
2021/02/16 09:00:38 packer-provisioner-shell plugin: Waiting for connection...
2021/02/16 09:00:38 packer-provisioner-shell plugin: Serving a plugin connection...
2021/02/16 09:00:38 Creating plugin client for path: /usr/local/bin/packer
2021/02/16 09:00:38 Starting plugin: /usr/local/bin/packer []string{"/usr/local/bin/packer", "plugin", "packer-provisioner-ansible"}
2021/02/16 09:00:38 Waiting for RPC address for: /usr/local/bin/packer
2021/02/16 09:00:38 packer-provisioner-ansible plugin: [INFO] Packer version: 1.6.6 [go1.15.5 darwin amd64]
2021/02/16 09:00:38 packer-provisioner-ansible plugin: Checking 'PACKER_CONFIG' for a config file path
2021/02/16 09:00:38 packer-provisioner-ansible plugin: 'PACKER_CONFIG' not set; checking the default config file path
2021/02/16 09:00:38 packer-provisioner-ansible plugin: Attempting to open config file: /Users/USER/.packerconfig
2021/02/16 09:00:38 packer-provisioner-ansible plugin: [WARN] Config file doesn't exist: /Users/USER/.packerconfig
2021/02/16 09:00:38 packer-provisioner-ansible plugin: Setting cache directory: /Users/USER/packer_cache
2021/02/16 09:00:38 packer-provisioner-ansible plugin: args: []string{"packer-provisioner-ansible"}
2021/02/16 09:00:38 Received unix RPC address for /usr/local/bin/packer: addr is /var/folders/kw/ljks13q92xg2d5chv2zy5km80000gp/T/packer-plugin274561758
2021/02/16 09:00:38 packer-provisioner-ansible plugin: Plugin address: unix /var/folders/kw/ljks13q92xg2d5chv2zy5km80000gp/T/packer-plugin274561758
2021/02/16 09:00:38 packer-provisioner-ansible plugin: Waiting for connection...
2021/02/16 09:00:38 packer-provisioner-ansible plugin: Serving a plugin connection...
2021/02/16 09:00:38 Preparing build: vsphere-iso
2021/02/16 09:00:39 packer-provisioner-ansible plugin: ansible-playbook version: 2.10.5
2021/02/16 09:00:39 Build debug mode: false
2021/02/16 09:00:39 Force build: true
2021/02/16 09:00:39 On error: ask
2021/02/16 09:00:39 Waiting on builds to complete...
vsphere-iso: output will be in this color.
2021/02/16 09:00:39 Starting build run: vsphere-iso
2021/02/16 09:00:39 Running builder: vsphere-iso
2021/02/16 09:00:39 [INFO] (telemetry) Starting builder vsphere-iso
2021/02/16 09:00:39 packer-builder-vsphere-iso plugin: No URLs were provided to Step Download. Continuing...
2021/02/16 09:00:39 packer-builder-vsphere-iso plugin: No CD files specified. CD disk will not be made.
==> vsphere-iso: Creating VM...
==> vsphere-iso: error creating vm: something went wrong when creating the VM
==> vsphere-iso: Step "StepCreateVM" failed
==> vsphere-iso: [c] Clean up and exit, [a] abort without cleanup, or [r] retry step (build may fail even if retry succeeds)? c
2021/02/16 09:00:43 [INFO] (telemetry) ending vsphere-iso
==> Wait completed after 3 seconds 760 milliseconds
2021/02/16 09:00:43 machine readable: error-count []string{"1"}
==> Some builds didn't complete successfully and had errors:
2021/02/16 09:00:43 machine readable: vsphere-iso,error []string{"error creating vm: something went wrong when creating the VM"}
==> Builds finished but no artifacts were created.
Build 'vsphere-iso' errored after 3 seconds 760 milliseconds: error creating vm: something went wrong when creating the VM
2021/02/16 09:00:43 [INFO] (telemetry) Finalizing.
==> Wait completed after 3 seconds 760 milliseconds
==> Some builds didn't complete successfully and had errors:
--> vsphere-iso: error creating vm: something went wrong when creating the VM
==> Builds finished but no artifacts were created.
2021/02/16 09:00:43 waiting for all plugin processes to complete...
2021/02/16 09:00:43 /usr/local/bin/packer: plugin process exited
2021/02/16 09:00:43 /usr/local/bin/packer: plugin process exited
2021/02/16 09:00:43 /usr/local/bin/packer: plugin process exited
Here is the VM builder JSON configuration:
"builders": [
{
"CPUs": 4,
"RAM": 16384,
"boot_command": [
"<enter><wait><f6><wait><esc><wait>",
"<bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"<bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"<bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"<bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"<bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"<bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"<bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"<bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"<bs><bs><bs>",
"/install/vmlinuz",
" initrd=/install/initrd.gz",
" priority=critical",
" locale=en_US",
" preeseed/url=http://url.com/preseed/ubuntu.cfg",
"<enter>"
],
"boot_wait": "10s",
"cdrom_type": "sata",
"cluster": "VxRail-Virtual-SAN-Cluster-1aec9d6d-843d-48c1-9000-ab08bb8e7907",
"content_library_destination": {
"cluster": "VxRail-Virtual-SAN-Cluster-1aec9d6d-843d-48c1-9000-ab08bb8e7907",
"folder": "folder/deployment/build",
"library": "VM Templates",
"resource_pool": "pool/deployment/continuous deployment"
},
"datastore": "VxRail-Virtual-SAN-Datastore-1aec9d6d-843d-48c1-9000-ab08bb8e7907",
"disk_controller_type": "nvme",
"folder": "folder/deployment/build",
"guest_os_type": "ubuntu64Guest",
"insecure_connection": true,
"ip_wait_timeout": "5m",
"iso_paths": [
"ISOs/ubuntu-18.04.5-server-amd64/ubuntu-18.04.5-server-amd64.iso"
],
"network_adapters": [
{
"network": "vCenter Server Network-1aec9d6d-843d-48c1-9000-ab08bb8e7907",
"network_card": "vmxnet3"
}
],
"password": "{{ user `vcenter_pass` }}",
"remove_cdrom": true,
"resource_pool": "pool/deployment/continuous deployment",
"shutdown_command": "echo '{{ user `ssh_pass` }}' | sudo -S systemctl poweroff",
"ssh_password": "{{ user `ssh_pass` }}",
"ssh_port": 22,
"ssh_username": "{{user `ssh_user`}}",
"storage": [
{
"disk_size": 204800,
"disk_thin_provisioned": true
}
],
"type": "vsphere-iso",
"username": "{{ user `vcenter_user` }}",
"vcenter_server": "vcenter.internet.net",
"vm_name": "ubuntu_template"
}
],
It places the VM in the correct folder and resource pool, it just fails out having not added a CDROM drive.