Logon Proxmox machine in terminal ssh root
Download latest ubuntu cloud LTS x64 image
–> wget https://cloud-images.ubuntu.com/jammy/current/jammy-server-cloudimg-amd64.img
From the same command-line, create a virtual machine with a ProxMox VMID of 990, with 2GB of RAM,1 vcpu, and named ubuntu-cloud-test using default network interface bridge:
qm create 990 –memory 2048 –name ubuntu-cloud-test –net0 virtio,bridge=vmbr0
Import the disk into the proxmox storage, into local-lvm in this case.
qm importdisk 990 ./jammy-server-cloudimg-amd64.img local-lvm
Add the new, imported disk to the VM (by VMID 990):
qm set 990 –scsihw virtio-scsi-pci –scsi0 local-lvm:vm-990-disk-0
Add a CD-ROM for Cloudinit
qm set 990 –ide2 local-lvm:cloudinit
Specify the boot disk:
qm set 990 –boot c –bootdisk scsi0
Add support for VNC and a serial console:
qm set 990 –serial0 socket –vga serial0
Convert to a template
qm template 990
Create a VM based on the template
qm clone 900 123 –name ubuntu-test123