Added initial support for Debian and Ubuntu to network module
This commit is contained in:
parent
42a3a74b7b
commit
230c2c0e2b
5 changed files with 85 additions and 1 deletions
|
@ -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' -%>
|
||||
|
|
3
network/templates/interfaces-gateway.erb
Normal file
3
network/templates/interfaces-gateway.erb
Normal file
|
@ -0,0 +1,3 @@
|
|||
<% if gateway != 'none' -%>
|
||||
gateway <%= gateway %>
|
||||
<% end -%>
|
16
network/templates/interfaces-if.erb
Normal file
16
network/templates/interfaces-if.erb
Normal 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 -%>
|
Loading…
Add table
Add a link
Reference in a new issue