On 14/10/16 09:14, Tom K. wrote:
> Hi,
> 
> I try to provision a vm machine with an alias/virtual Interface like eth0:1.
> So far so good. After the first build and the final Callback to Foreman
> I get an Exception in the foreman log so that the "wget" command to
> finish build cancels.
> 
[..]
> In the Snippet "preseed_networking_setup" I found this
> 
> <% @host.managed_interfaces.each do |interface| %>
> <% next if !interface.managed? || interface.subnet.nil? ||
> interface.primary -%>
> <% subnet = interface.subnet -%>
> <% virtual = interface.virtual? -%>
> <% dhcp = subnet.nil? ? false : subnet.dhcp_boot_mode? -%>
> real=`ip -o link | grep <%= interface.mac -%> | awk '{print $2;}' | sed
> s/:$//`
> <% if virtual -%>
> real=`echo <%= interface.identifier -%> | sed
> s/<%=*interface.physical_device* -%>/$real/`
> <% end -%>
> 
> But what's the correct Method for interface.physical_device?

It should probably be interface.attached_to, it was renamed back in
Foreman 1.7.0. If it works for you, please do send a fix to
https://github.com/theforeman/community-templates/blob/develop/snippets/preseed_networking_setup.erb.

-- 
Dominic Cleal
domi...@cleal.org

-- 
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.

Reply via email to