Added initial support for Debian and Ubuntu to network module

This commit is contained in:
Ossi Salmi 2010-11-19 16:48:25 +02:00 committed by Timo Mkinen
parent 42a3a74b7b
commit 230c2c0e2b
5 changed files with 85 additions and 1 deletions

View file

@ -4,7 +4,7 @@ HWADDR=<%= scope.lookupvar("macaddress_" + name) %>
<% end -%>
ONBOOT=yes
BOOTPROTO=<%= proto %>
<% if ipaddr != 'none' -%>
<% if ipaddr != 'none' and ipaddr != 'dhcp' -%>
IPADDR=<%= ipaddr %>
<% end -%>
<% if netmask != 'none' -%>

View file

@ -0,0 +1,3 @@
<% if gateway != 'none' -%>
gateway <%= gateway %>
<% end -%>

View file

@ -0,0 +1,16 @@
auto <%= name %>
<% if proto == 'none' -%>
iface <%= name %> inet manual
<% else -%>
iface <%= name %> inet <%= proto %>
<% end -%>
<% if ipaddr != 'none' and ipaddr != 'dhcp' -%>
address <%= ipaddr %>
<% end -%>
<% if netmask != 'none' -%>
netmask <%= netmask %>
<% end -%>
<% options.each do |val| -%>
<%= val %>
<% end -%>