Commit Graph

236 Commits

Author SHA1 Message Date
Naïm Favier
b8ee437596
Merge pull request #208643 from ncfavier/installer-test-tmp 2023-01-09 13:20:02 +01:00
Jörg Thalheim
c8104628f4 nixos/tests/installer/bcachefs: use ocr to type in password 2023-01-01 19:58:17 +01:00
Jörg Thalheim
13b0e42202 nixos/tests/installer: disable zfs for bcachefs tests
we are potentially testing very new kernels here, which are not
supported by zfs yet.
2023-01-01 19:58:17 +01:00
Naïm Favier
19cfb3e48c
nixos/tests/installer: test initrd secrets and nix-build
Both of those things rely on nixos-enter creating `/tmp` under the mount
point.
2023-01-01 17:20:37 +01:00
Artturin
05a2dfd674 lib.replaceChars: warn about being a deprecated alias
replaceStrings has been in nix since 2015(nix 1.10)

so it is safe to remove the fallback

d6d5885c15
2022-12-15 22:25:51 +02:00
Lily Foster
c2b3c9794d nixosTests: test spaces in mount options via btrfs subvols
Also enabled the btrfs tests for installer-systemd-stage-1 again
2022-11-06 22:15:35 +01:00
Robert Hensing
f40ff7f1f1 nixos/tests/installer: Add make-options-doc dep 2022-09-24 17:42:52 +01:00
Robert Hensing
618f82406f nixos/tests/installer: Fix docbook dependency 2022-09-24 17:38:10 +01:00
Madoura
39b9cf311b
nixos/tests/installer: add bcachefs tests 2022-05-04 19:26:43 -05:00
Bernardo Meurer
78f6f77962
Merge pull request #169113 from ElvishJerricco/systemd-stage-1-installer-tests
nixos: Installer tests for systemd stage 1
2022-04-30 13:18:57 -07:00
K900
adf3fe6811 nixos/tests/installer: disable vlans for initial VM
This saves 10-15 minutes of waiting for things to time out later.
2022-04-22 22:27:03 +03:00
K900
ed3cc9672a nixos/tests/installer: add missing dependency to image
Unbreaks nixosTests.installer.simple.
2022-04-22 21:03:46 +03:00
Will Fancher
9ee5d61a16 nixos: Installer tests for systemd stage 1 2022-04-17 18:31:35 -04:00
Vladimír Čunát
6427998d85
nixosTests.installer.*: provide a missing dependency
See errors in these three jobs:
https://hydra.nixos.org/eval/1753111#tabs-still-fail
It's a bit unpleasant that a single run of each test takes
almost an hour for me (half an hour on Hydra in some cases).
2022-04-05 18:55:56 +02:00
ajs124
16bce5f2fe nixosTests.installer.lvm: adjust root LV size
install ran out of disk space after 5b820f714d
2022-03-24 01:15:22 +01:00
pennae
6b8e88268e
Merge pull request #156213 from chkno/fix-install-tests
nixos/tests/install: Fix after sandboxed-docs change fc614c3
2022-01-29 00:15:53 +00:00
polykernel
4a9d9928dc nixos/nix-daemon: use structural settings
The `nix.*` options, apart from options for setting up the
daemon itself, currently provide a lot of setting mappings
for the Nix daemon configuration. The scope of the mapping yields
convience, but the line where an option is considered essential
is blurry. For instance, the `extra-sandbox-paths` mapping is
provided without its primary consumer, and the corresponding
`sandbox-paths` option is also not mapped.

The current system increases the maintenance burden as maintainers have to
closely follow upstream changes. In this case, there are two state versions
of Nix which have to be maintained collectively, with different options
avaliable.

This commit aims to following the standard outlined in RFC 42[1] to
implement a structural setting pattern. The Nix configuration is encoded
at its core as key-value pairs which maps nicely to attribute sets, making
it feasible to express in the Nix language itself. Some existing options are
kept such as `buildMachines` and `registry` which present a simplified interface
to managing the respective settings. The interface is exposed as `nix.settings`.

Legacy configurations are mapped to their corresponding options under `nix.settings`
for backwards compatibility.

Various options settings in other nixos modules and relevant tests have been
updated to use structural setting for consistency.

The generation and validation of the configration file has been modified to
use `writeTextFile` instead of `runCommand` for clarity. Note that validation
is now mandatory as strict checking of options has been pushed down to the
derivation level due to freeformType consuming unmatched options. Furthermore,
validation can not occur when cross-compiling due to current limitations.

A new option `publicHostKey` was added to the `buildMachines`
submodule corresponding to the base64 encoded public host key settings
exposed in the builder syntax. The build machine generation was subsequently
rewritten to use `concatStringsSep` for better performance by grouping
concatenations.

[1] - https://github.com/NixOS/rfcs/blob/master/rfcs/0042-config-option.md
2022-01-26 21:04:50 -05:00
Scott Worley
3f70c90d7a nixos/tests/installer: Fix race in bcache test
It looks like "make-bcache" also registers the devices, so the separate
registration afterwords is unnecessary.

Previously, the separate registration right afterwords didn't cause
a problem, presumably because it won the race with make-bcache's
registration.  After 1640359f33 slightly
changed the timing of command execution in tests, the separate
registration often fails with the error message "device already
registered", stopping the test.
2022-01-24 10:58:23 +01:00
Scott Worley
e7a1007725 nixos/tests/installer: Fix after sandboxed-docs change fc614c3 2022-01-23 00:09:19 -08:00
ajs124
a43c2c1e70 Revert "nixos/tests/installer: lvm: test lvm2-pvscan@ units"
This reverts commit 53a34361af.
2021-12-07 13:17:42 +01:00
Artturin
c19234d0df nixos/tests/installer: increase /boot sizes to 100MB 2021-11-30 03:53:14 +02:00
Artturi
c4851c0d71
Revert msize related commits (#147180) 2021-11-24 02:33:53 +02:00
Artturin
03e8e5848b nixos/tests/installer: increase memorySize to 3G
and increase the memory flags too
2021-11-21 23:06:58 +02:00
Sandro
07f29d2db2
Merge pull request #146829 from r-burns/isx86 2021-11-21 14:20:12 +01:00
Ryan Burns
2175b157ac treewide: refactor isi686 && isx86_64 -> isx86 2021-11-20 17:50:41 -08:00
Vladimír Čunát
60c5230968
nixosTests.installer: increase the VM memory
For me that fixes the i686 ZFS case:
https://hydra.nixos.org/build/158897777
I don't think it's worth chasing why RAM usage isn't very low here.
2021-11-20 23:00:43 +01:00
Bernardo Meurer
9c1d31ce68
nixos/tests/installer: comment out nixos-option test for now 2021-11-10 15:57:18 -08:00
Luke Granger-Brown
b942e0f650 nixos/tests/installer: don't break under i686
Currently, the installer tests just hang after the initial install phase
on i686 because qemu just quits because of the gic parameter.

Fix this by doing x86 things for both x86-64 and i686.
2021-05-03 01:44:54 +00:00
Samuel Dionne-Riel
7d112134de nixosTests.installer: Fix grub1 test being unreliable
The kernel sometimes assigns `/dev/sdb` to the 8GiB disk. This, in turn,
means the test will fail because we're targeting the wrong disk.

```
machine # [    0.000000] sd 2:0:0:0: [sda] 16777216 512-byte logical blocks: (8.59 GB/8.00 GiB)
machine # [    0.000000] sd 3:0:0:0: [sdb] 1048576 512-byte logical blocks: (537 MB/512 MiB)
```

```
machine # [    0.000000] sd 2:0:0:0: [sdb] 16777216 512-byte logical blocks: (8.59 GB/8.00 GiB)
machine # [    0.000000] sd 3:0:0:0: [sda] 1048576 512-byte logical blocks: (537 MB/512 MiB)
```

Note how the "sd x:0:0:0:` ID is stable. That is because QEMU **is**
told to give specific identifiers to the disks. So using the
dev/disk/by-id/ identifiers is stable.

* * *

Tested by forcing the sda/sdb swap this way:

    diff --git a/nixos/tests/installer.nix b/nixos/tests/installer.nix
    index 24c55081f9a..2eee224351b 100644
    --- a/nixos/tests/installer.nix
    +++ b/nixos/tests/installer.nix
    @@ -702,12 +702,19 @@ in {
               + " mkpart primary linux-swap 1M 1024M"
               + " mkpart primary ext2 1024M -1s",
               "udevadm settle",
    +      )
    +      print(machine.succeed("find /dev/disk/ '!' -type d -printf '%p → %l\n' | sort"))
    +      machine.succeed(
               "mkswap ${grubDevice}-part1 -L swap",
               "swapon -L swap",
               "mkfs.ext3 -L nixos ${grubDevice}-part2",
               "mount LABEL=nixos /mnt",
               "mkdir -p /mnt/tmp",
           )
    +      machine.succeed("echo success")
    +      machine.succeed(
    +          'if [[ "$(find ${grubDevice} -printf \'%l\')" != "../../sdb" ]]; then exit 22; else true; fi'
    +      )
         '';
         grubVersion = 1;
         # /dev/sda is not stable, even when the SCSI disk number is.

And ran this way:

     $ until (clear; tmux clear ; time env -i nix-build nixos/release-combined.nix -A nixos.tests.installer.grub1.x86_64-linux); do echo derp; done
2021-04-25 19:59:29 -04:00
Jacek Galowicz
bc7a369c68
Merge pull request #112961 from r-burns/nixos-test-grub
nixosTests.installer: fix non-zfs grub tests
2021-02-18 11:58:57 +01:00
Ryan Burns
5406db08bf nixosTests.installer: increase EFI partition size
Needed for simpleUefiGrub test to pass on aarch64
Runs out of space otherwise
2021-02-18 01:58:25 -08:00
Ryan Burns
5828d54356 nixosTests.installer: fix non-zfs grub tests
Now that grub2 is built without zfs support when possible, this is a
separate store path which may need to be made available to the installer.
2021-02-12 19:39:17 -08:00
Anders Kaseorg
4a0a7ccb2a nixosTests.installer: Increase memory allocated to the VM
Fixes #111223.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2021-01-31 12:45:42 -08:00
Vladimír Čunát
fe111fc679 nixosTests.zfs.installer: fixup test after d44c6219b8 2021-01-24 21:02:56 +01:00
Kevin Cox
4ee9a86405
Merge pull request #109042 from Atemu/installer-tests-more-cores
tests/installer: give installer VM more cores
2021-01-18 06:14:50 -05:00
Dominik Xaver Hörl
25bef2d8f9 treewide: simplify pkgs.stdenv.lib -> pkgs.lib
The library does not depend on stdenv, that `stdenv` exposes `lib` is
an artifact of the ancient origins of nixpkgs.
2021-01-10 20:12:06 +01:00
Atemu
71590db8fb tests/installer: give installer VM more cores
ZFS installer test runtime went from 637s to 380s on my Ryzen 3600
2021-01-10 13:45:14 +01:00
Vladimír Čunát
85afe9cbe9
nixos/tests/installer: increase RAM in the VM
1G apparently isn't sufficient anymore, at least in swraid case:
https://hydra.nixos.org/build/126561574
2020-09-07 15:43:37 +02:00
Vladimír Čunát
6eea644749
nixos/tests/installer swraid: increase partition size
We apparently didn't fit anymore.  I don't think this test is meant
to (also) check closure size.

Note: as of this commit, the test is blocked by a fontconfig problem,
so I tested with that merge temporarily reverted.
2020-09-05 19:29:38 +02:00
Anders Kaseorg
f4b2c9dfe7 cryptsetup, lvm2, systemd: Break cyclic dependency at a different point
The cyclic dependency of systemd → cryptsetup → lvm2 → udev=systemd
needs to be broken somewhere.  The previous strategy of building
cryptsetup with an lvm2 built without udev (#66856) caused the
installer.luksroot test to fail.  Instead, build lvm2 with a udev built
without cryptsetup.

Fixes #96479.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2020-09-03 12:35:56 -07:00
Matthew Bauer
ca3fa9c32a
Merge pull request #95956 from matthewbauer/qemu-cpu-max
runInLinuxVM, test-driver: use -cpu max instead of -cpu host
2020-08-26 12:59:57 -05:00
Vladimír Čunát
e02793de2f
nixos installer tests: add a missing package
Tested it locally fixes #96361
nix-build nixos/release-combined.nix -A nixos.tests.installer.lvm.x86_64-linux -Q
2020-08-26 18:14:34 +02:00
ajs124
b4fab1cdff nixosTests.installer.btrfsSubvolDefault: fix warning 2020-08-23 16:10:02 +02:00
Matthew Bauer
47b56e7c19 runInLinuxVM, test-driver: use -cpu max instead of -cpu host
This appears to avoid requiring KVM when it’s not available. This is
what I originally though -cpu host did. Unfortunately not much
documentation available from the QEMU side on this, but this appears
to square with help:

$ qemu-system-x86 -cpu help
...
x86 host                  KVM processor with all supported host features
x86 max                   Enables all features supported by the accelerator in the current host
...

Whether we actually want to support this not clear, since this only
happens when your CPU doesn’t have full KVM support. Some Nix builders
are lying about kvm support though. Things aren’t too slow without it
though.

Fixes https://github.com/NixOS/nixpkgs/issues/85394

Alternative to https://github.com/NixOS/nixpkgs/pull/83920
2020-08-21 23:42:07 -05:00
Vladimír Čunát
5475b84859
nixos/tests/installer lvm: increase partition size
We apparently didn't fit anymore.  I don't think this test is meant
to (also) check closure size.
2020-07-25 22:57:27 +02:00
ajs124
53a34361af nixos/tests/installer: lvm: test lvm2-pvscan@ units
Also, add some sleep statements in between, which seems to at least feel
like it causes

> WARNING: Device /dev/vda* not initialized in udev database even after waiting 10000000 microseconds.

To occur less frequently.

This eventually still succeeds after some amount of waiting, I suspect
some racyness in the way lvm's udev-triggered scripts trigger other
units.
2020-07-14 12:00:33 +02:00
ajs124
d056f6e86d nixos/test/installer: add postBootCommands 2020-07-14 12:00:33 +02:00
Jacek Galowicz
11f49fb94d
Merge pull request #79966 from chkno/bcache
nixos/bcache: Installer test for / on bcache
2020-05-12 18:21:44 +02:00
Chuck
f9091581e8 nixos/tests/installer: Fix machine name 2020-05-11 15:41:18 -07:00
Benjamin Staffin
f09b8be73d installer test: Fix grub extraConfig syntax
It looks like `terminal_output.serial` is incorrect, according to the
grub documentation:

https://www.gnu.org/software/grub/manual/grub/html_node/Serial-terminal.html

Related PR: #79406
2020-04-22 20:30:19 -04:00
Graham Christensen
ec2d28e323
specialisation: replace nesting with named configurations
Co-authored-by: worldofpeace <worldofpeace@protonmail.ch>
2020-04-12 08:12:50 -04:00
Michael Weiss
216a7e7a98
nixosTests.installer: Don't wait for the nixos-manual service
The nixos-manual service was removed in #83199 but we missed the check
in this test which prevents the "tested" job from succeeding [0][1].

[0]: https://hydra.nixos.org/build/115472896
[1]: https://hydra.nixos.org/build/115472896/nixlog/94/tail
2020-03-26 01:21:34 +01:00
Chuck
f6e9deee3c nixos/bcache: Installer test for / on bcache 2020-02-12 17:40:05 -08:00
Jacek Galowicz
059845b11d nixosTests.installer: Port to python 2020-02-07 13:24:16 +01:00
volth
2bd296a7e9 runInLinuxVM, test-driver: pass host's cpu type to guest vm
'kvm64' is the most generic CPU, which does not support SSE4.2, AVX and other ISA extentions.
2020-01-15 23:35:00 +00:00
Franz Pletz
ec6224b6cd Revert "installer: Disable udisks"
This reverts commit 571fb74f44.

The dependency on gtk2 was removed.

Co-authored-by: Florian Klink <flokli@flokli.de>
2019-10-16 20:31:24 -04:00
Venkateswara Rao Mandela
bc68f85326 nixos/tests: add test for showing child configuration in grub menu
- Create a child configuration named "Work" with an extra config file.
- Name the default configuration as "Home" :-)
- Once the VM is setup, reboot and verify that it has booted into
default configuration.
- Reboot into the "Work" configuration via grub.
- Verify that we have booted into the "Work" configuration and that
the extra config file is present.

This test works for the simple grub configuration and simple UEFI
Grub configuration. UEFI Systemd is not included in the test.
2019-07-11 17:40:25 +05:30
Venkateswara Rao Mandela
b08400a4d2 nixos/tests: installer: restructure simpleUefiGrub test data 2019-07-11 17:38:25 +05:30
Venkateswara Rao Mandela
c400ab55d6 nixos/tests: installer: restructure simple test data 2019-07-11 17:38:25 +05:30
Franz Pletz
c51786bd5d
nixos/tests: fix luksroot installer test name
Both tests were previously called "luksroot-luks2".
2019-06-08 12:14:03 +02:00
Andreas Rammhold
839a37fdd2
nixos/tests/installer: add cryptsetup tests for LUKS format 2 & default format 2019-03-02 13:56:52 +01:00
Jörg Thalheim
b5c1deca8a
treewide: remove wkennington as maintainer
He prefers to contribute to his own nixpkgs fork triton.
Since he is still marked as maintainer in many packages
this leaves the wrong impression he still maintains those.
2019-01-26 10:05:32 +00:00
Symphorien Gibol
2dbed7e726 nixos/tests/installer.nix: shorten test name to fit length limit
previously one of the tests would fail with

boot-after-install: starting vm
Path length (109) is longer than maximum supported length (108) and will be truncated at /nix/store/0ingn8cwwnl84i374hcl6nafsm2c5m2p-perl-5.28.0/lib/perl5/5.28.0/x86_64-linux-thread-multi/Socket.pm line 872, <__ANONIO__> line 268.
boot-after-install# qemu-system-x86_64: -monitor unix:./monitor: Failed to connect socket ./monitor: No such file or directory
error: QEMU died prematurely
QEMU died prematurely
vde_switch: EOF on stdin, cleaning up and exiting
cleaning up
builder for '/nix/store/zbpxwwxwy7f6z5z3kg4nf5mjqsywzjvx-vm-test-run-installer-filesystemEncryptedWithKeyfile.drv' failed with exit code 4

Shortening the test name fixes the issue.
2018-11-17 22:30:29 +01:00
Léo Gaspard
6c68fbd4e1
tests: refactor to carry the package set as an argument
This way, the package set will be possible to pass without re-importing
all the time
2018-11-11 23:11:45 +09:00
Uli Baum
7dd6a5192d nixos/tests/installer: stop udev queue before calling mdadm
In the swraid test, temporarily stop udev queue execution while
creating mdraid devices to prevent a race with udev, see
https://groups.google.com/forum/#!topic/scylladb-dev/u87yHgo3ylU
2018-09-22 12:33:15 +02:00
Uli Baum
c46677fec2 nixos/tests/installer: use flock for all parted calls
to further reduce risk of race with udev, like util-linux
recommends for sfdisk:
https://github.com/karelzak/util-linux/blob/v2.32/disk-utils/sfdisk.8#L71
2018-09-22 12:22:17 +02:00
Uli Baum
a5183762c5 nixos/tests/installer: prevent race between parted and udev
by combining all parted commands into a single parted call.
This eliminates one cause of non-deterministic failure.
2018-09-22 01:32:06 +02:00
Samuel Dionne-Riel
b63c539bdc nixos/tests/installer: grub1 needs /tmp to exist. 2018-09-17 09:31:43 -04:00
Uli Baum
43e30b1ead nixos/tests/installer: add missing system.extraDependencies
Since 1b11fdd0df the test VM
depends on some extra packages to build the system to be installed.
This broke the installer test as it tried to download/build these
packages in a sandbox.
2018-09-01 11:50:02 +02:00
Samuel Dionne-Riel
bc5b26b4ab Reviews use of old nixos wallpaper to use one with the new logo.
The wallpaper used is *structurally compatible* with the other one,
meaning that the logo is at the same location, and not bigger.

It has one drawback: the logo is brighter, which clashes with the grub
usage. This is to be fixed with new options in grub.
2018-08-29 00:04:58 -04:00
aszlig
f51dc2a94b
nixos/tests/luksroot: Fix OCR of passphrase prompt
Since a9d69a74d6, the passphrase prompt
now no longer starts with "Enter passphrase for" but now it's just
"Passphrase for", which causes the luksroot installer test to fail.

I've tested this on a x86_64-linux machine and the test now succeeds.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @oxij, @samueldr
Issue: #29441
2018-08-11 00:07:10 +02:00
volth
2e979e8ceb [bot] nixos/*: remove unused arguments in lambdas 2018-07-20 20:56:59 +00:00
Frederik Rietdijk
1a6af9f88e
Merge pull request #43857 from volth/unused
[bot] treewide: remove unreferenced code
2018-07-20 21:06:32 +02:00
volth
87f5930c3f [bot]: remove unreferenced code 2018-07-20 18:48:37 +00:00
Matthew Bauer
76999cc40e treewide: remove aliases in nixpkgs
This makes the command ‘nix-env -qa -f. --arg config '{skipAliases =
true;}'’ work in Nixpkgs.

Misc...

- qtikz: use libsForQt5.callPackage

  This ensures we get the right poppler.

- rewrites:

  docbook5_xsl -> docbook_xsl_ns
  docbook_xml_xslt -> docbook_xsl

diffpdf: fixup
2018-07-18 23:25:20 -04:00
Florian Klink
89d5d191b4 nixos/tests: users.(extraUsers|extraGroup->users|group) 2018-06-30 02:31:30 +02:00
Vladimír Čunát
a8c71037e0
installer tests: avoid udisks2
This is a temporary hack to fix channel until we resolve #42324.
2018-06-22 10:47:05 +02:00
aszlig
fa0b60f59a
nixos/tests/installer: Add lndir to extraDeps
In commit 17dd7bcd89 the systemd unit
generator now uses lndir instead of "ln -s", so we need to have lndir
available in the Nix store for the installer tests to be able to build
the units and thus the whole system.

This should fix the installer tests, although I have only tested it with
the "simple" subtest.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @jtojnar, @xeji, @edolstra
2018-05-15 18:51:53 +02:00
Tuomas Tynkkynen
3131daace1 nixos/tests/installer: Give eval failure on unsupported boot methods 2018-03-24 16:11:31 +02:00
Tuomas Tynkkynen
e58624a877 nixos/tests: Make simpleUefiGrub test work on AArch64
Needs more refactoring for the AArch64 '-enable-kvm' stuff some day...
2018-03-21 23:19:26 +02:00
Eelco Dolstra
ceb0a28e8c
Don't try hashed mirrors in the installer test 2018-02-27 20:30:06 +01:00
Eelco Dolstra
9e8cf40c7e
nixos/tests/installer.nix: Don't use a writable store
This is no longer needed.
2018-02-27 20:22:14 +01:00
Eelco Dolstra
f64a4af328
Fix comments 2018-02-07 19:32:41 +01:00
Tuomas Tynkkynen
3be9d4610f nixos/tests: Drop unnecessary qemu-flags.nix include
None of these files are using anything from there.
2018-01-30 16:57:27 +02:00
Vladimír Čunát
474c1ce799
nixos.tests.installer.swraid: increase drive size
The latest staging caused this test not to fit anymore.
I'm all for keeping closure sizes under control,
but I don't think *this* is a good place.
2017-11-25 07:46:28 +01:00
Bjørn Forsman
aedba5c2af nixos: run parted with --script option (3rd)
Doh, should have included this in previous commit.

Ref. 0ff4bb5f87
("nixos: run parted with --script option").
2017-11-19 22:55:12 +01:00
Bjørn Forsman
bf338ab9ee nixos: run parted with --script option (2nd)
Ref. 0ff4bb5f87
("nixos: run parted with --script option")
2017-11-19 22:50:24 +01:00
Franz Pletz
bdbaaad7de
Merge pull request #29269 from Moredread/test_crypt_with_keyfile
Test opening encrypted filesystem with keyfile
2017-11-19 20:30:59 +01:00
Tuomas Tynkkynen
cbccb1edf5
nixos installer tests: Add UEFI Grub test
Fixed merge conflict. Closes #22923.
2017-11-14 11:30:28 +01:00
Bjørn Forsman
0ff4bb5f87 nixos: run parted with --script option
-s, --script: never prompts for user intervention

Sometimes the NixOS installer tests fail when they invoke parted, e.g.
https://hydra.nixos.org/build/62513826/nixlog/1. But instead of exiting
right there, the tests hang until the Nix builder times out (and kills
the build). With this change the tests would instead fail immediately,
which is preferred.

While at it, use "parted --script" treewide, so nobody gets build
timeout due to parted error (or misuse). (Only nixos/ use it, and only
non-interactive.)

A few instances already use the short option "-s", convert them to long
option "--short".
2017-10-14 15:29:02 +02:00
André-Patrick Bubel
58374fbaf3
Test opening encrypted filesystem with keyfile
Checks for regression of missing cryptsetup, when no luks device without
keyfile is configured
2017-09-14 04:20:15 +02:00
Vladimír Čunát
dc93744273
rogue: omit from the installation media
At least for now.  It would increase the ISO size by ~10 MB,
after the fixup in the parent commit.
2017-08-29 16:15:15 +02:00
Tuomas Tynkkynen
b471e125c2 nixos/tests/installer: Add stdenvNoCC to extraDependencies
The installer tests are failing after 505e94256e
due to `nixos-rebuild switch` in the installed system trying to build
stdenvNoCC.

Seems that previously, stdenvNoCC wasn't in the installed
system either, but all the direct dependencies for the build were
(I don't really understand why, for that matter), so the building
actually went fine and everything worked.

But now gcc is also a direct build dependency due to allowedRequisites
containing gcc (even though it doesn't become a runtime dependency)
which doesn't get to the installed system.

All in all, let's ensure stdenvNoCC actually gets to the installed
system. It's after all necessary in almost any NixOS config build.
2017-08-24 02:07:56 +03:00
Tuomas Tynkkynen
0488cb1802 tests/installer: Rename simpleUefiGummiboot -> simpleUefiSystemdBoot
It hasn't been called Gummiboot for ages.
2017-08-19 08:46:48 +02:00
Graham Christensen
b0a4c2c33f
nixos: installer.nix test: test ZFS install use case 2017-06-28 19:45:20 -04:00
romildo
aa8018103c nixos-artwork: add more wallpapers
Restructure the nixos-artwork to make it easy to selectively
incorporate other components from upstream without needing to download
the full package.

Until now only the Gnome_Dark wallpaper was included. Add other
wallpapers available in the package repository.
2017-06-07 18:00:58 -03:00
Joachim Fasting
252dcd62f3
OVMF: separate output for ovmf binaries
OVMF{,CODE,VARS}.fd are now available in a dedicated fd output, greatly
reducing the closure in the common case where only those files are used (a
few MBs versus several hundred MBs for the full OVMF).

Note: it's unclear why `dontPatchELF` is now necessary for the build to
pass (on my end, at any rate) but it doesn't make much sense to run this
fixup anyway,

Note: my reading of xen's INSTALL suggests that --with-system-ovmf should
point directly to the OVMF binary.  As such, the previous invocation was
incorrect (it pointed to the root of the OVMF tree).  In any case, I have
only built xen with `--with-system-ovmf`, I have not tested it.

Fixes https://github.com/NixOS/nixpkgs/issues/25854
Closes https://github.com/NixOS/nixpkgs/pull/25855
2017-05-20 12:33:48 +02:00
Dan Peebles
d990aa7163 Refactor nixos-install to separate out filesystem build logic
The key distinction I'm drawing is that there's a component that deals
with the store of the machine being built, and another component for
the store building it. The inner part of it assumes nothing from the
builder (doesn't need chroot or root powers) so it can run comfortably
inside a Nix build, as well as nixos-rebuild. I have some upcoming work
that will use that to significantly speed up and streamline image builds
for NixOS, especially on virtualized hosts like EC2, but it's also a
reasonable speedup on native hosts.
2017-04-16 16:09:41 +00:00
Robin Gloster
b79fa22b7a
tests.installer: rely on swap.target in tests
fixes #5258
2017-01-25 17:00:13 +01:00
obadz
74b3ad148d nixos/tests/installer.nix: add libxml2 & libxslt to prevent download attempts 2016-08-09 17:01:42 +01:00