I’ve been able to provision VMware hosts using PXEbooting a couple dozen times.
Now, I’m interested in provisioning VMware hosts using “Image provisioning without SSH” and I’m a little confused about what I need.
Question 1: The instructions say
Enable user_data checking the proper checkbox in the compute resource definition
If I browse to “Infrastructure > Compute Resources > my vCenter instance > Edit”, there is no checkbox for user_data. However, I do see an option under “Images”.
Is that referring to this screen under “Infrastructure > Compute Resources > my vCenter instance > Images”? (It’s not a Compute Resource itself, but it’s an image/template within the Compute Resource).
If I continue with the provisioning at this step, Foreman complains with the error ERF42-5701 [Foreman::Exception]: The user-data template must be a hash in YAML format for VM customization to work.
What did I miss? Can I have a finish template and a user data template associated with the same OS?
yes, the user data needs to be set on image level, not compute resource itself. We’d appreciate improvements to our documentation to make it clearer. Changes go to https://github.com/theforeman/theforeman.org
I think the template should be listed there. Make sure it is assigned to the org/loc that you create the host in. Also maybe you need to disassociate the finish template.
Yeah, the template seems to be in the right org/loc. When I disassociate the finish template, Foreman complains that it cannot find any templates at all:
Unfortunately, creating a new HostGroup does not lead to the desired result.
I observed the following behavior:
If no host group is selected, the UserData template is used but not the cloud-init.
When selecting the host group, the Kickstart default finish template is used, but not the cloud-init.
I followed the steps as in the instructions. It has also worked so far without any problems. The images which have worked before now unfortunately no longer work. Do you have any idea where to look up how the decision of the used template is made?