* Replace ifconfig by ip in the initrd of VM tests.
svn path=/nixos/trunk/; revision=26280
This commit is contained in:
parent
8ce36ffb3a
commit
cd30b40da7
@ -247,14 +247,16 @@ in
|
|||||||
# We need mke2fs in the initrd.
|
# We need mke2fs in the initrd.
|
||||||
cp ${pkgs.e2fsprogs}/sbin/mke2fs $out/bin
|
cp ${pkgs.e2fsprogs}/sbin/mke2fs $out/bin
|
||||||
|
|
||||||
# And `ifconfig'.
|
# And `ip' (which needs libresolv.so).
|
||||||
cp ${pkgs.nettools}/sbin/ifconfig $out/bin
|
cp ${pkgs.iproute}/sbin/ip $out/bin
|
||||||
|
cp ${pkgs.glibc}/lib/libresolv.so.* $out/lib
|
||||||
'';
|
'';
|
||||||
|
|
||||||
boot.initrd.postDeviceCommands =
|
boot.initrd.postDeviceCommands =
|
||||||
''
|
''
|
||||||
# Set up networking. Needed for CIFS mounting.
|
# 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
|
# If the disk image appears to be empty, run mke2fs to
|
||||||
# initialise.
|
# initialise.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user