@olivierlambert I managed to set the "User config" stuff by terraform. What I can't seem to get my head around is how to set the "Network config" for the nocloud provider via terraform. Are there examples tf files that I could take as a starting off point?
@fohdeesha So if nocloud is the only datasource that does allow to configure the newly created VM's network, how is the network configured in all the other cases? For the terraform vshere provider I can see it done via "customize { network_interface { ipv4_address ".
How do they get that information to the inside of the machine? Do they use the guest-tools to manipulate the interface settings? And how should this work on XCP-ng? I was under the impression that the guest tools were only reporting the network settings from the guest to the host.
What I want to do with terraform and cloud-init, is to create a private network with multiple VMs where I can reliably connect from one machine to another by their IP.
If I can't configure the IP settings with terraform via cloud-init, but assuming that I can set the MAC addresses via terraform, I guess I will have to go with a DHCP server with static mapping of MAC to IP there.