I got the following user data template to work for vmware image based 
provisioning without SSH:

identity:
  LinuxPrep:
    domain: <%= @host.domain%>
    hostName: <%= @host.shortname%>

globalIPSettings:
  dnsServerList: [<%= @host.primary_interface.subnet.dns_primary %>, <%= 
@host.primary_interface.subnet.dns_secondary %>]
  dnsSuffixList: [<%= @host.domain %>]

nicSettingMap:
<% @host.interfaces.each do |interface| %>
  - adapter:
      ip: <%= interface.ip %>
      subnetMask: <%= interface.subnet.mask %>
      <% if interface.primary -%>gateway: [<%= interface.subnet.gateway 
%>]<% end %>
<% end %>

However, the thing to know is that image based provisioning against vmware 
without ssh is very limited when compared with traditional cloud-init. You 
are basically limited to the following properties:
https://pubs.vmware.com/vsphere-55/index.jsp?topic=%2Fcom.vmware.wssdk.smssdk.doc%2Fvim.vm.customization.Specification.html

Which means you can pass basic network settings to bootstrap the box, but 
little more. Windows clients can do a little more sysprep related activity, 
but Linux is limited. This means you will almost certainly need to design 
some form of "firstboot" process to handle things like re-registration to 
foreman, initial puppet run, etc. So far the only thing I haven't figured 
out is how to "phone_home" to complete the build. All I've been able to do 
is cancel the build in the web UI once it is done.

-- 
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/foreman-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to