install_xen_orchestra v0.5.0 — build your own cloud-init VM templates
As I am sure most of you know that XOA Hub is not accessible from Xen Orchestra from sources.
So v0.5.0 of my install script adds a VM Template Library — a new
--build-templates flag (and menu entry) that builds the equivalent on your own pool, from each distribution's own published cloud image.
./install-xen-orchestra.sh --build-templates
It runs from your workstation over SSH against the pool master, like --deploy does. Nothing is installed locally and your XO install isn't touched.
What you get
A sealed template that shows up next other vm templates you have, with:
cloud-init — supply an SSH key or a full cloud-config at VM creation.
XCP-ng guest tools, installed from guest-tools.iso on the pool. Without these XO never reports the VM's IP. On Debian 13 there's no
xe-guest-utilities package, and a failed package install doesn't stop cloud-init, so an apt-first approach silently gives you a template that looks fine and is useless. The ISO is what the XCP-ng docs prescribe anyway.
A scrubbed identity — machine-id, SSH host keys, cloud-init state and logs are all wiped before sealing, so clones don't collide on DHCP leases or share an SSH fingerprint.
growroot, so the disk size you ask for at creation is actually filled.
One template for both BIOS and UEFI — the Debian generic images carry an ESP and a BIOS boot partition, so you just flip "Boot firmware" in XO's advanced settings. The build itself isn't prompted for storage or network —
it uses your pool's default SR (or the emptiest one, if you haven't set a default) and the management network. Both are just build-time choices; you pick whatever you want when you actually create a VM from the template.
Images are pulled from the distribution's own mirror (nothing redistributed), downloaded onto the pool master so the ~3 GB never crosses your workstation's link, and verified against the origin's published SHA512SUMS at build time
—so new upstream releases get picked up without me editing anything.
Allow roughly five to ten minutes per template; it has to boot the VM once to
install the guest agent and run the scrub.
Distros
Debian 13 (Trixie) is the only one for now. That's a starting point, not the limit — the catalogue is a table with one row per distro, and adding another is a row in that table, not a change to the build.
So: comment here if there's a specific distro you'd want to see sooner rather than later and I'll prioritise accordingly.
Repo: https://github.com/acebmxer/install_xen_orchestra
Docs for this feature: https://github.com/acebmxer/install_xen_orchestra/blob/main/docs/templates.md