nutanix-cloud-native / packer-plugin-nutanix

Packer Builder for Nutanix AHV
https://developer.hashicorp.com/packer/integrations/nutanix-cloud-native/nutanix
Apache License 2.0
35 stars 19 forks source link

Ubuntu 20.04, 22.04, 23.04 Live Server ISO is ignoring or not detecting the cloud-init config-2 drive #160

Closed rolffujino closed 6 months ago

rolffujino commented 1 year ago

/kind bug

What steps did you take and what happened: When trying to generate an Ubuntu 22.04 LTS image using packer and Nutanix, from the ubuntu-22.04.3-live-server-amd64 ISO using cloud-init user_data with autoinstall, it never finds the cloud-init configs, times out and goes to the GUI installer.

Packer trace logs just shows that packer is waiting on an IP address and no information of importance.

What did you expect to happen: When using packer with VMware to do the same thing, it discovers the cloud-init configs and performs an autoinstall.

Anything else you would like to add: When you go into the grub command line and list devices (ls -l) the CDROM drive from Nutanix for the cloud-init config-2 drive is not shown/accessible. It is only accessible/visible after running nativedisk command, however the contents are following cloud-init standards and valid json, yaml and subiquity: image image image image

This issue is not limited to Nutanix packer plugin, it also occurs when using custom script through the GUI in Nutanix and manually adding a CDROM with an ISO with the cloud-init config drive contents.

The cloud-init works when using the ubuntu-22.04-server-cloudimg-amd64 but since the OS is already installed, it prevents customisation of partition tables etc.

Environment:

tuxtof commented 1 year ago

Hello @rolffujino

there is few errors in the method you try to use

You can also use the autoinstall arg to skip confirmation.

And if you want a full e2e automatic experience , as we don't support yet the boot_cmd in packer , best is to switch to a netboot install so you can modify your grub/pxe config at the source and add autoinstall and correct ds mode