[PATCH] extend eth{} to optionally take a list of IPv6 addresses

Matt Domsch Matt_Domsch at dell.com
Fri Aug 28 21:11:09 UTC 2009


From: Matt Domsch <mdomsch at puppet1.fedora.phx.redhat.com>

---
 configs/system/generic-network.conf.erb |    4 ++++
 manifests/filetypes/interfaces.pp       |    2 +-
 2 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/configs/system/generic-network.conf.erb b/configs/system/generic-network.conf.erb
index 07ece31..f4366dd 100644
--- a/configs/system/generic-network.conf.erb
+++ b/configs/system/generic-network.conf.erb
@@ -19,3 +19,7 @@ BRIDGE=<%= brname %>
 <% else -%>
 TYPE=Ethernet
 <% end -%>
+
+<% if ipv6addrs.length then -%>
+IPV6ADDR_SECONDARIES="<%= ipv6addrs.map{|ip| ip }.join(" ") %>"
+<% end -%>
diff --git a/manifests/filetypes/interfaces.pp b/manifests/filetypes/interfaces.pp
index 1a7f30e..29722f6 100644
--- a/manifests/filetypes/interfaces.pp
+++ b/manifests/filetypes/interfaces.pp
@@ -1,6 +1,6 @@
 # Define ethernet devices (usually aliased)
 
-define eth($ipaddr, $netmask) {
+define eth($ipaddr, $netmask, $ipv6addrs=[]) {
     $bootproto='static'
     $device = $name
     $ethtype = "standard"
-- 
1.5.5.6




More information about the Fedora-infrastructure-list mailing list