serve templates for cloud-init nocloud provider
vSphere offers the functionality to clone vm from templates and customize the templates during cloning. This is very handy for changing the network settings of a newly cloned VM. Foreman fully supports this feature via a userdata template that is converted to cloud-init. The amount of things vSphere allows a user to customize are very limited, though. It's not possible to run a finish script or setup puppet with valid certificates on the new VM. This can be worked around by setting up a two step process: vSphere customization is just used to set up the network config of the host. Cloud-init is used to do the rest of the customization on first boot.
As part of this story, Foreman should be able to serve cloud-init templates.
cloud-init can be configured this way:
Foreman than needs to respond to:
/userdata/meta-data (with metadata)
userdata/user-data (with a cloud-init template)
This has already been implemented in a plugin, see https://github.com/theforeman/foreman_userdata.