Author: sandervanderburg
Date: Tue Oct 12 19:44:32 2010
New Revision: 24247
URL: https://svn.nixos.org/websvn/nix/?rev=24247&sc=1
Log:
More stealing from NixOS' qemu-vm.nix module to get it working again. It's
obviously better to reuse NixOS' qemu-vm.nix, but I cannot figure out how to
get the proper network settings configured so that our socket file hack works
Modified:
disnix/disnix-vm-addons/trunk/data/generate-infrastructure.nix
disnix/disnix-vm-addons/trunk/data/qemu-vm.nix
Modified: disnix/disnix-vm-addons/trunk/data/generate-infrastructure.nix
==============================================================================
--- disnix/disnix-vm-addons/trunk/data/generate-infrastructure.nix Tue Oct
12 19:39:30 2010 (r24246)
+++ disnix/disnix-vm-addons/trunk/data/generate-infrastructure.nix Tue Oct
12 19:44:32 2010 (r24247)
@@ -15,7 +15,8 @@
in
" "+targetName+" = {\n"+
" backdoor = \"@[email protected]\";\n"+
- " hostname = \"${targetName}\";\n"
+ " hostname = \"${targetName}\";\n"+
+ " system = \"i686-linux\";"
+
(if config.services.tomcat.enable then
" tomcatPort = 8080;\n"
Modified: disnix/disnix-vm-addons/trunk/data/qemu-vm.nix
==============================================================================
--- disnix/disnix-vm-addons/trunk/data/qemu-vm.nix Tue Oct 12 19:39:30
2010 (r24246)
+++ disnix/disnix-vm-addons/trunk/data/qemu-vm.nix Tue Oct 12 19:44:32
2010 (r24247)
@@ -131,7 +131,7 @@
-initrd ${config.system.build.toplevel}/initrd \
${qemuGraphics} \
$QEMU_OPTS \
- -append "$(cat ${config.system.build.toplevel}/kernel-params)
init=${config.system.build.bootStage2}
systemConfig=${config.system.build.toplevel} regInfo=${regInfo}
${kernelConsole} $QEMU_KERNEL_PARAMS" \
+ -append "$(cat ${config.system.build.toplevel}/kernel-params)
init=${config.system.build.toplevel}/init regInfo=${regInfo} ${kernelConsole}
$QEMU_KERNEL_PARAMS" \
${config.virtualisation.qemu.options}
'';
@@ -167,9 +167,12 @@
boot.initrd.postDeviceCommands =
''
+ # Workaround for massive clock drift with the "kvm-clock" clock source.
+ echo hpet >
/sys/devices/system/clocksource/clocksource0/current_clocksource
+
# Set up networking. Needed for CIFS mounting.
ifconfig eth0 up 10.0.2.15
-
+
# If the disk image appears to be empty, run mke2fs to
# initialise.
FSTYPE=$(blkid -o value -s TYPE /dev/vda || true)
_______________________________________________
nix-commits mailing list
[email protected]
http://mail.cs.uu.nl/mailman/listinfo/nix-commits