[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [OSSTEST PATCH 27/62] ts-host-install: Break out $persistent_net_rules



We're going to want to reuse this value.

Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---
 ts-host-install | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/ts-host-install b/ts-host-install
index 8ea81e24..f80a151c 100755
--- a/ts-host-install
+++ b/ts-host-install
@@ -195,6 +195,9 @@ sub setup_netboot_firstboot($) {
        system_checked @cmd;
     }
 
+    my $persistent_net_rules =
+       "$initrd_overlay.d/etc/udev/rules.d/70-persistent-net.rules";
+
     my $ipappend = 2;
     my $wantphysif= get_host_property($ho,'interface force','auto');
     logm("Forcing interface $wantphysif");
@@ -206,7 +209,7 @@ sub setup_netboot_firstboot($) {
        # ip(8) moved to /sbin in Jessie
        my $ipcmd = $ho->{Suite} =~ m/wheezy/ ? "/bin/ip" : "/sbin/ip";
         file_simple_write_contents
-            ("$initrd_overlay.d/etc/udev/rules.d/70-persistent-net.rules",
+            ($persistent_net_rules,
              $ho->{Flags}{'force-mac-address'} ? <<END : <<END);
 SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", KERNEL=="$wantphysif", RUN += 
"$ipcmd link set $wantphysif address $ho->{Ether}"
 END
-- 
2.11.0


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.