Good thing. I believe ifconfig is deprecated a long time ago and it's use 
should be avoided.


-----Original Message-----
From: [email protected] on behalf of Eelco Dolstra
Sent: Fri 3/11/2011 3:59 PM
To: [email protected]
Subject: [Nix-commits] SVN commit: nix - r26280 
-nixos/trunk/modules/virtualisation
 
Author: eelco
Date: Fri Mar 11 14:59:36 2011
New Revision: 26280
URL: https://svn.nixos.org/websvn/nix/?rev=26280&sc=1

Log:
* Replace ifconfig by ip in the initrd of VM tests.

Modified:
   nixos/trunk/modules/virtualisation/qemu-vm.nix

Modified: nixos/trunk/modules/virtualisation/qemu-vm.nix
==============================================================================
--- nixos/trunk/modules/virtualisation/qemu-vm.nix      Fri Mar 11 14:50:11 
2011        (r26279)
+++ nixos/trunk/modules/virtualisation/qemu-vm.nix      Fri Mar 11 14:59:36 
2011        (r26280)
@@ -247,14 +247,16 @@
       # We need mke2fs in the initrd.
       cp ${pkgs.e2fsprogs}/sbin/mke2fs $out/bin
 
-      # And `ifconfig'.
-      cp ${pkgs.nettools}/sbin/ifconfig $out/bin
+      # And `ip' (which needs libresolv.so).
+      cp ${pkgs.iproute}/sbin/ip $out/bin
+      cp ${pkgs.glibc}/lib/libresolv.so.* $out/lib
     '';
       
   boot.initrd.postDeviceCommands =
     ''
       # Set up networking.  Needed for CIFS mounting.
-      ifconfig eth0 up 10.0.2.15
+      ip link set eth0 up
+      ip addr add 10.0.2.15/24 dev eth0
 
       # If the disk image appears to be empty, run mke2fs to
       # initialise.
_______________________________________________
nix-commits mailing list
[email protected]
http://mail.cs.uu.nl/mailman/listinfo/nix-commits

_______________________________________________
nix-dev mailing list
[email protected]
https://mail.cs.uu.nl/mailman/listinfo/nix-dev

Reply via email to