Commit Graph

180 Commits

Author SHA1 Message Date
Eelco Dolstra
82e1d0c8b1 Remove services.ttyBackgrounds
This hasn't worked in a long time.
2013-09-26 17:33:52 +02:00
Eelco Dolstra
b825169404 Add kexec support
You can now do a fast reboot (bypassing the BIOS, which may take
several minutes on servers) by running ‘systemctl kexec’.

Unfortunately the QEMU test for this is unreliable due to a QEMU bug
(it randomly crashes with a message like ‘Guest moved used index from
8 to 0’), so it's commented out.
2013-09-16 17:42:13 +02:00
Eelco Dolstra
e06cd403b8 Execute NixOS VM tests on a separate machine 2013-09-02 11:18:22 +02:00
aszlig
b32ef4dbef
test-driver/Machine: Add new allowReboot flag.
This is to actually allow for the target machine to reboot, which could
come in handy for some VM tests in NixOps. Well, actually to be more
specific: We need it for the Hetzner NixOps backend test. :-)

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2013-07-31 23:25:09 +02:00
Eelco Dolstra
57c35c94ca Use the qemu-kvm wrapper 2013-07-31 14:53:27 +02:00
Eelco Dolstra
6620a0f679 Fix the installer tests
E.g. http://hydra.nixos.org/build/5561399
2013-07-17 13:01:12 +02:00
Eelco Dolstra
99b501a767 Don't pull in the old qemu-kvm 2013-07-16 13:53:54 +02:00
Eelco Dolstra
80c5b807d2 Fix tree toggles in VM tests 2013-06-14 13:50:00 +02:00
Rob Vermaas
960bb2bcd3 Fix nixos test driver startJob function. It was stopping the job before. 2013-03-20 20:45:43 +01:00
Rickard Nilsson
f9b05ac1fe Parameterise the path to nixpkgs.
This makes it possible to build several NixOS systems that use different
nixpkgs in the same nix-build invocation. Today, you can't do that since
the <nixpkgs> path reference is hard-coded in lib/eval-config.nix.
2013-01-28 16:11:44 +01:00
Mathijs Kwik
ebf4816717 systemd mount units: use 'escapeSystemdPath' from lib/utils 2013-01-01 14:53:54 +01:00
Eelco Dolstra
97f087cd44 Turn networking.interfaces into an attribute set
Thus

  networking.interfaces = [ { name = "eth0"; ipAddress = "192.168.15.1"; } ];

can now be written as

  networking.interfaces.eth0.ipAddress = "192.168.15.1";

The old notation still works though.
2012-11-02 17:08:11 +01:00
Eelco Dolstra
e5d4524dda Test driver: Don't wait for a reply after issuing "poweroff" 2012-10-30 17:01:21 +01:00
Eelco Dolstra
3d6824feaa Machine.pm: Don't add .service implicitly
Systemd will add .service anyway if no unit type is given.
2012-10-19 10:32:09 -04:00
Eelco Dolstra
3f6d53cc97 Move escapeSystemdPath to lib/utils.nix
The new file ‘utils.nix’ is intended for NixOS-specific library
functions (i.e. stuff that shouldn't go into Nixpkgs' lib/).
2012-10-12 17:01:49 -04:00
Eelco Dolstra
13a5ebad32 Update some tests for systemd 2012-10-04 12:34:44 -04:00
Eelco Dolstra
08f14b33c1 Merge branch 'master' of github.com:NixOS/nixos into systemd 2012-08-20 11:27:38 -04:00
Eelco Dolstra
a025e7e7e2 Provide a common share between VMs to allow easy communication
Every VM now mounts a common SMB share on /tmp/shared.
2012-08-16 10:47:33 -04:00
Shea Levy
1b615f460b Allow overriding all NixOS tests to run with the minimal kernel possible for that test's config(s) (based on requiredKernelConfig) 2012-08-04 09:45:26 -04:00
Eelco Dolstra
d4fec178fd Merge remote-tracking branch 'origin/master' into systemd 2012-08-02 13:44:16 -04:00
Eelco Dolstra
87ae768665 Fix the LVM installer test
GRUB 2 doesn't want to boot off a LVM disk:

machine# installing the GRUB 2 boot loader on /dev/vda...
machine# Path `/boot/grub' is not readable by GRUB on boot. Installation is impossible. Aborting.
machine# /nix/store/7yc535h1lim1a5gkhjb3fr6c8193dv8w-install-grub.pl: installation of GRUB on /dev/vda failed

In theory GRUB 2 supports booting from LVM, but we probably need to
generate the right grub.conf (see
https://wiki.archlinux.org/index.php/GRUB2#LVM).

http://hydra.nixos.org/build/2904680
2012-07-26 16:02:33 -04:00
Eelco Dolstra
1a2b3cc5e4 Fix the tests.installer.grub1 test
GRUB 1 doesn't understand /dev/vda, so use a SCSI rather than virtio disk.
2012-07-26 16:02:33 -04:00
Marc Weber
47e67f5e9c renaming all occurrences of /var/run/{booted,current}-system
in particular those found in docs
still keeping old path in modules/config/shells.nix for unkown reason (?)
2012-07-23 14:01:35 -04:00
Eelco Dolstra
1cde1bdbe6 nixos-run-vms: If there is only one VM, attach stdio to its serial console
This is useful for interactive testing (quicker than logging in via
SSH and more convenient than logging in via a virtual console).
2012-07-20 12:03:15 -04:00
Eelco Dolstra
82019c01bb Test driver: exit when all VMs have exited rather than sleeping forever 2012-06-22 14:31:07 -04:00
Eelco Dolstra
387f1d6032 * Forgot to commit.
svn path=/nixos/trunk/; revision=33938
2012-04-27 08:47:51 +00:00
Eelco Dolstra
6c1bb54483 * In the installation CD, make the NixOS/Nixpkgs available as if they
were obtained from the NixOS channel.  "nixos-install" copies this
  to the installed system as well.
* In the installation CD, set GC_INITIAL_HEAP_SIZE to a low value for
  the benefit of memory-constrained environments.

svn path=/nixos/trunk/; revision=33887
2012-04-23 00:41:37 +00:00
Eelco Dolstra
fa50d105d7 * Pass -cpu kvm64 in NixOS VMs (and add a simple regression test for
GMP).

svn path=/nixos/trunk/; revision=33849
2012-04-19 18:56:35 +00:00
Eelco Dolstra
1d0c23bffb * Use a raw disk for the installer test. This speeds it up by almost
two minutes on my laptop.  Note that due to sparse allocation, raw
  disks don't actually take up more space than qcow2 disks (and
  they're temporary anyway).

svn path=/nixos/trunk/; revision=33746
2012-04-11 10:05:29 +00:00
Eelco Dolstra
a395e46192 * Fix the NFS Upstart dependencies. Mountd is now started before
nfsd, as suggested by the nfs-utils README.

  Also, rather than relying on Upstart events (which have all sorts of
  problems, especially if you have jobs that have multiple
  dependencies), we know just let jobs start their on prerequisites.
  That is, nfsd starts mountd in its preStart script; mountd starts
  statd; statd starts portmap.  Likewise, mountall starts statd to
  ensure that it can mount NFS filesystems.  This means that doing
  something like "start nfsd" from the command line will Do The Right
  Thing and start the dependencies of nfsd.

svn path=/nixos/trunk/; revision=33172
2012-03-16 20:10:14 +00:00
Shea Levy
8efda48496 Enable building an efi-bootable ISO
svn path=/nixos/trunk/; revision=33140
2012-03-16 05:37:24 +00:00
Eelco Dolstra
29d84af677 * Remove the use of the NIXPKGS and NIXOS environment variables.
Instead use $NIX_PATH.  NIXOS_CONFIG is still supported.

svn path=/nixos/trunk/; revision=32739
2012-03-02 12:38:22 +00:00
Peter Simons
d16fdad9fd Revert "split release.nix into helpers and the jobs themselves".
Change r32480 was made due to a misunderstanding.

svn path=/nixos/trunk/; revision=32512
2012-02-23 12:00:05 +00:00
Peter Simons
bd9b32620c split release.nix into helpers and the jobs themselves
this allows for external use of the helpers, for example to build custom cds without editing release.nix

svn path=/nixos/trunk/; revision=32480
2012-02-22 20:28:57 +00:00
Peter Simons
eb6e1310b8 strip trailing whitespace; no functional change
svn path=/nixos/trunk/; revision=29285
2011-09-14 18:20:50 +00:00
Eelco Dolstra
d75efe4aa1 * For security, don't mount the entire host filesystem.
svn path=/nixos/trunk/; revision=28429
2011-08-09 14:07:44 +00:00
Eelco Dolstra
8aad8c536f * Make virtualisation.qemu.options a list.
svn path=/nixos/trunk/; revision=28120
2011-08-02 06:52:10 +00:00
Eelco Dolstra
2dc81fc9dd * Shut up warnings about QEMU_OPTS being undefined.
svn path=/nixos/trunk/; revision=27982
2011-07-28 09:41:07 +00:00
Eelco Dolstra
650d14be8d * Remove most references to the "services" tree.
svn path=/nixos/trunk/; revision=26990
2011-04-27 13:16:33 +00:00
Eelco Dolstra
0f544f1ea8 * Add a command `forwardPort' to forward a TCP port on the host to a
TCP port on the guest.  Useful during testing (e.g. to access a web
  server in the guest through a web browser on the host).

svn path=/nixos/trunk/; revision=26987
2011-04-27 09:54:17 +00:00
Rob Vermaas
22a4047b1b NixOS/124: The system_tarball Hydra job should define a build product
svn path=/nixos/trunk/; revision=26788
2011-04-12 07:45:54 +00:00
Eelco Dolstra
c430bf5cc3 * Add virtio_console to the CD because the backdoor requires it.
* The booted CD no longer requires "-net user".

svn path=/nixos/trunk/; revision=26427
2011-03-19 08:58:56 +00:00
Eelco Dolstra
be0fca5781 * Use QEMU/KVM's paravirtualised console device for the backdoor.
This has the advantage that it doesn't depend on networking being
  up.
* Move common QEMU/KVM guest configuration to profiles/qemu-guest.nix.

svn path=/nixos/trunk/; revision=26421
2011-03-18 12:38:22 +00:00
Eelco Dolstra
8ce36ffb3a * Use "ip" instead of "ifconfig" for setting up network interfaces,
since the latter is rather deprecated and has been unmaintained
  since 2001.  Note that "ip" doesn't know about classful addressing,
  so you can no longer get away with not specifying the subnet mask
  for explicitly configured interfaces.  So if you had

    networking.interfaces =
      [ { name = "eth0"; ipAddress = "192.168.1.1"; } ];

  this should be changed to

    networking.interfaces =
      [ { name = "eth0";
          ipAddress = "192.168.1.1";
          subnetMask = "255.255.255.0";
        }
     ];

  otherwise you end up with a subnet mask of 255.255.255.255.

svn path=/nixos/trunk/; revision=26279
2011-03-11 14:50:11 +00:00
Eelco Dolstra
158a60465f * The vde_switch startup code was reading from the wrong filehandle,
so the startup synchronisation didn't work, causing spurious QEMU
  failures ("Device 'vde' could not be initialized").

svn path=/nixos/trunk/; revision=26055
2011-02-22 10:41:11 +00:00
Eelco Dolstra
32aa967ee1 * Only add a VDE NIC if there is a webserver.
svn path=/nixos/trunk/; revision=25986
2011-02-16 10:07:28 +00:00
Eelco Dolstra
49213aa80a * Doh! Exceptions outside of subtests were silently ignored.
svn path=/nixos/trunk/; revision=25981
2011-02-15 15:04:17 +00:00
Sander van der Burg
96b769c979 Removed the backdoor, because it does not work anymore and it has also become obsolete (Disnix uses something else now)
svn path=/nixos/trunk/; revision=25601
2011-01-17 16:15:59 +00:00
Eelco Dolstra
066f76e65f * Remove "nix-build tests -A foo.vms; ./result/bin/run-vms" as a way
to run the VMs of a test.  Instead, you can do

    $ nix-build tests -A foo.driver
    $ ./result/bin/nixos-run-vms

  This uses the test driver infrastructure, which is necessary in
  order to set up the VDE switches.

svn path=/nixos/trunk/; revision=25586
2011-01-16 14:21:47 +00:00
Eelco Dolstra
88a4fda7d8 * Don't daemonise vde_switch so that it's cleaned up automatically.
This is useful for interactive use.

svn path=/nixos/trunk/; revision=25570
2011-01-14 16:01:47 +00:00