I think if the autoprovisioning fails, managed host should be created instead of the discovered one.
Can you please send the result of GET /api/v2/hosts/<my-new-host-id>? Also I would like to see the result of host's ENC rendering. It should be available through the UI: 1. Go to hosts list 2. Click on the new host 3. Look for YAML button above host's properties table. My wild guess would be that the OS is not set for the host for some reason. On Tuesday, November 28, 2017 at 12:40:56 AM UTC+2, Garreat wrote: > > My Foreman version is: *Version 1.15.6 * > Discovery plugin: *9.1.5* > > In my PXELinux provisioning template, I use the *host_param('param_name')* > construct to access parameters assigned *to the operating system*. Just > as described here: > http://projects.theforeman.org/projects/foreman/wiki/templatewriting#Host-or-host-group-parameters > . > This works fine -- however... > > If a single hostgroup parameter exists (don't mistake with Puppet class > parameter), then Discovery auto-provision fails to resolve the > *host_param('param_name') > **from the operating system parameters*. > *<%= host_param('os_param_name') %> *gets populated with nothing (empty > string). > Same goes for the old syntax *<%= **@host.params['parameter_name'] %> *. > > This happens only when using auto-provision. Does *not* occur when: > - using 'Provision' on a discovered host > - using 'Build' on hosts page > - using 'Rebuild config' on hosts page > > > Probably just a minor code stuff... Help appreciated. > -- You received this message because you are subscribed to the Google Groups "Foreman users" group. To unsubscribe from this group and stop receiving emails from it, send an email to foreman-users+unsubscr...@googlegroups.com. To post to this group, send email to foreman-users@googlegroups.com. Visit this group at https://groups.google.com/group/foreman-users. For more options, visit https://groups.google.com/d/optout.