Injecting per-VM identity with cloud-init
Cloning gives you fifteen identical machines. Cloud-init is what makes each one itself on first boot — its hostname, its IP, its login.
The flow for creating a VM here is a small, repeatable recipe:
1. clone the template (9999) -> new VM with the next free ID
2. set its resources (CPU / RAM / disk)
3. attach a per-VM cloud-init snippet:
- hostname = the VM's name
- static IP = 10.100.100.<VMID - 100> (the address convention)
- the login password = <REDACTED>
4. start it -> cloud-init applies all of the above on first boot
The address convention does a lot of quiet work: a VM's IP is simply its Proxmox ID minus 100, so the snippet can compute the address with no lookup, and a human can always map ID to IP in their head.
The snippet is a small templated file — placeholders for hostname and password get filled in per VM, attached for the first boot, then removed afterward so no per-VM secret lingers on the host.
Why we use this: cloud-init is the standard way to turn a generic image into a specific machine, on every platform from a laptop VM to a cloud fleet. Learning it here, on Proxmox, is the same skill you'd use to bootstrap a thousand cloud instances.
Diagram

No comments to display
No comments to display