Commit Graph

8905 Commits

Author SHA1 Message Date
Maximilian Bosch
91365cd23a nexus: fix setup and nixos test (#40522)
The original `nexus` derivation required `/run/sonatype-work/nexus3`
which explicitly depended on the NixOS path structure.

This would break `nexus` for everyone using `nixpkgs` on a non-NixOS
system, additionally the module never created `/run/sonatype-work`, so
the systemd unit created in `services.nexus` fails as well. The issue
wasn't actively known as the `nixos/nexus` test wasn't registered in
Hydra (see #40257).

This patch contains the following changes:

* Adds `tests.nexus` to `release.nix` to run the test on Hydra.

* Makes JVM parameters configurable: by default all JVM options were located
  in `result/bin/nexus.vmoptions` which made it quite hard to patch
  these parameters. Now it's possible to override all parameters by
  running `VM_OPTS_FILE=custom-nexus.vmoptions ./result/bin/nexus run`
  (after patching the `nexus` shell script), additionally it's possible
  to override these parameters with `services.nexus.vmoptions`.

* Bumped Nexus from 3.5.1 to 3.11.0

* Run the `nexus` test on Hydra with `callTest` in `nixos/release.nix`,
  furthermore the test checks if the UI is available on the specified
  port.

* Added myself as maintainer for the NixOS test and the package to have
  some more people in case of further breakage.

* Added sufficient disk space to the `nexus` test, otherwise the service
  fails with the following errors:

  ```
  com.orientechnologies.orient.core.exception.ODatabaseException: Cannot create database 'accesslog'
  com.orientechnologies.orient.core.exception.OLowDiskSpaceException: Error occurred while executing
    a write operation to database 'accesslog' due to limited free space on the disk (242 MB). The database
    is now working in read-only mode. Please close the database (or stop OrientDB), make room on your hard
    drive and then reopen the database. The minimal required space is 256 MB. Required space is now set to
    256MB (you can change it by setting parameter storage.diskCache.diskFreeSpaceLimit) .
  ```

/cc @ironpinguin @xeji
2018-05-15 14:10:29 +02:00
John Ericson
f2017c40ae Merge remote-tracking branch 'upstream/master' into staging 2018-05-14 22:53:10 -04:00
Uli Baum
dd73ab0092 nixos/tests: prevent stateVersion warnings in eval
... introduced by 1f0b6922d3
continuation of 88fa50c2f2
2018-05-15 00:22:35 +02:00
John Ericson
8e891e6ed4 Merge remote-tracking branch 'upstream/master' into staging 2018-05-14 10:57:33 -04:00
xeji
642bed4b3e
nixos/tests/acme: fix on i686, improve timing (#40410)
... to prevent non-deterministic failures
2018-05-13 19:59:59 +02:00
xeji
c482b41f40
Merge pull request #40373 from xeji/fix-mesos-test
nixos/mesos: fix non-deterministic service and test failure
2018-05-13 19:57:24 +02:00
Frederik Rietdijk
658b7c3f2e Merge master into staging 2018-05-13 12:13:25 +02:00
John Ericson
2c5d915200 Merge commit '92b7a814f26ee1d37e989431c18518c67285a332' into staging 2018-05-13 01:02:09 -04:00
Jan Malakhovski
095fe5b43d nixos: rename system.{stateVersion,defaultChannel} -> system.nixos.\1 2018-05-12 19:27:09 +00:00
xeji
a19cc36e1a
nixos/tests/mysql-backup: fix non-deterministic failure (#40258)
Sometimes failed because of delayed creation of the backup file.
2018-05-12 11:37:35 +02:00
Tim Steinbach
92cf881675
Merge pull request #40390 from xeji/kafka
nixos/tests/kafka: fix and refactor tests
2018-05-11 22:02:53 -04:00
Uli Baum
13f83ba05f nixos/tests/kafka: fix and refactor tests
- refactor into single file for all versions
- improve timing, prevent non-deterministic failures
- fix tests for i686-linux
2018-05-12 02:16:25 +02:00
John Ericson
ee4b56edd3 Merge remote-tracking branch 'upstream/master' into staging 2018-05-11 14:36:08 -04:00
Uli Baum
0d2a4ed49c nixos/tests/mesos: wait for all services and ports
to be available before sending requests.
Avoids non-deterministic test failure.
2018-05-11 19:26:35 +02:00
Uli Baum
840e5d8bda nixos/tests/graphite: fix test
- adapt netcat options to libressl-nc
- wait for services to be started and accepting connections
2018-05-10 23:30:56 +02:00
John Ericson
67db915a43 Merge remote-tracking branch 'upstream/master' into staging 2018-05-10 16:35:04 -04:00
xeji
558f4b3368
nixos/tests/plotinus: fix non-deterministic failure (#40239)
Test failed sometimes, likely because a window didn't get focus.
2018-05-10 19:38:02 +02:00
John Ericson
42f6e7c4e4 Merge remote-tracking branch 'upstream/master' into staging 2018-05-10 12:04:17 -04:00
Robert Schütz
da58afdd68 nixos/tests/home-assistant: print log before failing 2018-05-10 13:12:35 +02:00
Frederik Rietdijk
64c8c6dcb3 Merge master into staging 2018-05-10 09:30:56 +02:00
Uli Baum
844698c436 nixos/tests/statsd: fix non-deterministic failure
Test failed sometimes because the service took more time to start.
2018-05-09 12:38:09 +02:00
Matthew Bauer
6748534d83 Merge remote-tracking branch 'upstream/master' into staging 2018-05-08 09:36:00 -05:00
aszlig
78b4b90d6c
Merge pull request #39526 (improve dhparams)
This introduces an option that allows us to turn off stateful generation
of Diffie-Hellman parameters, which in some way is still "stateful" as
the generated DH params file is non-deterministic.

However what we can avoid with this is to have an increased surface for
failures during system startup, because generation of the parameters is
done during build-time.

Aside from adding a NixOS VM test it also restructures the type of the
security.dhparams.params option, so that it's a submodule.

A new defaultBitSize option is also there to allow users to set a
system-wide default.

I added a release notes entry that described what has changed and also
included a few notes for module developers using this module, as the
first usage already popped up in NixOS/nixpkgs#39507.

Thanks to @Ekleog and @abbradar for reviewing.
2018-05-08 02:09:46 +02:00
aszlig
81fc2c3509
nixos/dhparams: Add a defaultBitSize option
This allows to set the default bit size for all the Diffie-Hellman
parameters defined in security.dhparams.params and it's particularly
useful so that we can set it to a very low value in tests (so it doesn't
take ages to generate).

Regardless for the use in testing, this also has an impact in production
systems if the owner wants to set all of them to a different size than
2048, they don't need to set it individually for every params that are
set.

I've added a subtest to the "dhparams" NixOS test to ensure this is
working properly.

Signed-off-by: aszlig <aszlig@nix.build>
2018-05-07 04:58:52 +02:00
aszlig
1eeeceb9c7
nixos/nsd: Allow to configure root zone
When trying to run NSD to serve the root zone, one gets the following
error message:

error: illegal name: '.'

This is because the name of the zone is used as the derivation name for
building the zone file. However, Nix doesn't allow derivation names
starting with a period.

So whenever the zone is "." now, the file name generated is "root"
instead of ".".

I also added an assertion that makes sure the user sets
services.nsd.rootServer, otherwise NSD will fail at runtime because it
prevents serving the root zone without an explicit compile-time option.

Tested this by adding a root zone to the "nsd" NixOS VM test.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @hrdinka, @qknight
2018-05-07 04:05:41 +02:00
Uli Baum
c3eefe801a fleet: remove package, module, test
deprecated and unmaintained upstream
2018-05-05 00:28:16 +02:00
Uli Baum
f039bf9abc panamax: remove packages, module and test
was broken and depends on (deprecated) fleet
packages: panamax_api, panamax_ui
2018-05-05 00:27:15 +02:00
John Ericson
cf06e42d1c Merge remote-tracking branch 'upstream/master' into staging 2018-05-03 16:35:36 -04:00
Matthew Justin Bauer
eeb016e8f0
Merge branch 'staging' into fix-ncurses-darwin-extensions 2018-05-02 15:40:38 -05:00
Robin Gloster
fe9096ef09
Merge branch 'master' into docker-registry-enhancements 2018-05-02 13:12:57 +02:00
Michele Catalano
afd3136e8e
nixos/docker-registry: Add support for garbage collector to docker registry 2018-05-01 15:23:47 +02:00
Maximilian Bosch
593dc45141
nixos/docker-registry: cleanup module definition & enhance testcase
The following changes have been applied:

- the property `http.headers.X-Content-Type-Options` must a list of
  strings rather than a serialized list
- instead of `/etc/docker/registry/config.yml` the configuration will be
  written with `pkgs.writeText` and the store path will be used to run
  the registry. This reduces the risk of possible impurities by relying
  on the Nix store only.
- cleaned up the property paths to easy readability and reduce the
  verbosity.
- enhanced the testcase to ensure that digests can be deleted as well
- the `services.docker-registry.extraConfig` object will be merged with
  `registryConfig`

/cc @ironpinguin
2018-05-01 15:23:39 +02:00
Julien Langlois
519b64592d hitch: init at 1.4.8 + service + test (#39358)
Add the Hitch TLS reverse proxy as an option for TLS termination.
2018-05-01 10:36:36 +01:00
Maximilian Bosch
e12cc85b07
nixos/osquery: add test
Some time ago I fixed the broken package `osquery` (see #39336).
I had to test the package manually by starting the daemon locally,
however this doesn't ensure that the module is still functional.

In order to cover the package *and* the integration with the NixOS
module I thought that adding a testcase might be the best idea.

The current testcase does the following things:

* Starts an `osqueryd` service in a test machine with customized logger
  path and PID file

* Ensures that the `osqueryd.service` unit is running

* Checks if the customized flags (`pidfile`, `logger_path`) are applied
  to `osquery`.

* Performs a simple test query against the `etc_hosts` database to check
  if the basic funcitonality of `osquery` (storing system information into
  a database) works fine.
2018-04-30 16:49:38 +02:00
aszlig
1907120f23
nixos/tests/udisks2: Fix USB device hotplug
The usb_add and usb_del monitor commands have been removed in QEMU
version 2.12 (introduced in 3e3b39f173).

Quote from https://wiki.qemu.org/ChangeLog/2.12#Incompatible_changes:

> The deprecated HMP commands "usb_add" and "usb_del" have been removed.
> Use "device_add" and "device_del" as replacement instead.

So we're doing exactly that and the udisks2 test now works again.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @edolstra
2018-04-30 03:02:57 +02:00
aszlig
146cb02542
nixos/tests/hibernate: Fix netcat flags
I'm not sure why 024b501907 used -q 0
because even netcat-openbsd has the -N flag which IMO is the better way
to shutdown the socket on EOF.

Our default netcat implementation has changed once again[1] in
3c3b82234a and we're now using LibreSSL's
implementation, which doesn't have a -q flag.

See https://github.com/NixOS/nixpkgs/pull/39634 for the pull request
introducing the switch.

[1]: https://github.com/NixOS/nixpkgs/pull/19982

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @matthewbauer, @dtzWill, @Mic92
2018-04-29 23:46:47 +02:00
aszlig
97adb03a9e
nixos/tests/predictable-interface-names: Refactor
The Nix expression here is really hard to read with multiple (and
unnecessarily) nested lets and it also generates attribute names based
on the derivation generated by makeTest, which will result in these
attribute names:

  * vm-test-run-predictableInterfaceNames
  * vm-test-run-predictableInterfaceNames-with-networkd
  * vm-test-run-unpredictableInterfaceNames
  * vm-test-run-unpredictableInterfaceNames-with-networkd

With the refactor the attribute names are now:

  * predictable
  * predictableNetworkd
  * unpredictable
  * unpredictableNetworkd

So now the code is even shorter and IMHO slightly more readable.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @symphorien, @fpletz, @adisbladis
2018-04-29 15:36:56 +02:00
Tim Steinbach
9774c8a0de
linux-copperhead: Fix test 2018-04-28 20:20:47 +00:00
aszlig
1b1b76f70a
nixos/tests/chromium: Wait 10s after new window
This is a very very very ugly workaround and it's because Chromium seems
to eat keystroke for a few seconds after a new window is created.

I haven't found a better solution yet, so let's at least unbreak the
test until we come up with a better way.

Thanks to @vcunat for bringing this to my attention and also doing the
initial bisect.

The change that brought up this problem was 2b29e40153,
which updated Chromium from version 65.0.3325.181 to version
66.0.3359.117. Unfortunately the upstream changelog[1] is way too large
to actually guess what the breaking change is.

[1]: https://chromium.googlesource.com/chromium/src/+log/65.0.3325.181..66.0.3359.117?pretty=fuller&n=10000

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @bendlas, @vcunat
2018-04-28 17:35:13 +02:00
aszlig
3e11ff6e0d
nixos/dhparams: Introduce a 'stateful' option
This option allows us to turn off stateful generation of Diffie-Hellman
parameters, which in some way is still stateful as the generated DH
params file is non-deterministic.

However what we can avoid with this is to have an increased surface for
failures during system startup, because generation of the parameters is
done during build-time.

Another advantage of this is that we no longer need to take care of
cleaning up the files that are no longer used and in my humble opinion I
would have preferred that #11505 (which puts the dhparams in the Nix
store) would have been merged instead of #22634 (which we have now).

Luckily we can still change that and this change gives the user the
option to put the dhparams into the Nix store.

Beside of the more obvious advantages pointed out here, this also
effects test runtime if more services are starting to use this (for
example see #39507 and #39288), because generating DH params could take
a long time depending on the bit size which adds up to test runtime.

If we generate the DH params in a separate derivation, subsequent test
runs won't need to wait for DH params generation during bootup.

Of course, tests could still mock this by force-disabling the service
and adding a service or activation script that places pre-generated DH
params in /var/lib/dhparams but this would make tests less readable and
the workaround would have to be made for each test affected.

Note that the 'stateful' option is still true by default so that we are
backwards-compatible with existing systems.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @Ekleog, @abbradar, @fpletz
2018-04-26 08:04:50 +02:00
aszlig
761266bd18
nixos/dhparams: Turn params into a submodule
We're going to implement an option which allows us to turn off stateful
handling of Diffie-Hellman parameter files by putting them into the Nix
store.

However, modules now might need a way to reference these files, so we
add a now path option to every param specified, which carries a
read-only value of the path where to find the corresponding DH params
file.

I've also improved the description of security.dhparams.params a bit so
that it uses <warning/> and <note/>.

The NixOS VM test also reflects this change and checks whether the old
way to specify the bit size still works.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @Ekleog
2018-04-26 08:04:48 +02:00
aszlig
4de774a63b
nixos/dhparams: Add a VM test
We're going to make changes to the dhparams module so we really want to
make sure we don't break it, so having a NixOS VM test is to make sure
we don't blow things up and can iterate on it.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @Ekleog
2018-04-26 08:04:45 +02:00
Matthew Justin Bauer
e4d2d32a32
Merge pull request #33679 from flokli/deluge-module
Deluge: use mkEnableOption, add test
2018-04-25 14:54:34 -05:00
Jan Tojnar
ad589329e7
nixos/release.nix: add tests.gdk-pixbuf 2018-04-25 18:37:44 +02:00
Sarah Brofeldt
25abc29f47
Merge pull request #39473 from xeji/update-keymap-test
nixos/tests/keymap: wait for xdotool to succeed
2018-04-25 11:17:53 +02:00
xeji
6891bda370 nixos/tests/keymap: wait for xdotool to succeed
xdotool failed in rare cases when a window was already created
but not yet decorated by the window manager.
also prevent a (never observed but possible) race condition
2018-04-25 10:16:52 +02:00
Peter Hoeg
45f1205bab
Merge pull request #39304 from peterhoeg/f/ha
home-assistant: add a few knobs and make config YAML
2018-04-25 01:35:12 +00:00
Sarah Brofeldt
65abd2e63f
Merge pull request #39400 from xeji/improve-keymap-tests
nixos/tests/keymap: improve keymap tests
2018-04-24 11:49:53 +02:00
xeji
84a6e18947 nixos/tests/keymap: improve keymap tests
simplify tests, prevent timeouts and non-deterministic failures
2018-04-24 11:13:48 +02:00
Peter Hoeg
b886faa6b6 home-assistant: use remarshal to convert configuration to YAML
HA doesn't mind the configuration being JSON instead of YAML but since YAML is
the official language, use that as it allows users to easily exchange config
data with other parties in the community.
2018-04-23 16:53:13 +08:00
Matthew Justin Bauer
e4717c902f
Merge pull request #27958 from LumiGuide/strongswan-swanctl
nixos: add the strongswan-swanctl service
2018-04-21 15:47:39 -05:00
Jörg Thalheim
dc0653f54f
Merge pull request #38816 from Ekleog/dovecot-lda-test
dovecot module: test dovecot's LDA
2018-04-21 19:55:23 +01:00
Jörg Thalheim
bf6998bdfa
Merge pull request #39297 from xeji/tests/gnome3-gdm
nixos/tests/gnome3-gdm: fix broken test
2018-04-21 11:40:52 +01:00
xeji
4c14202bd1 nixos/tests/gnome3-gdm: fix broken test
test always failed due to multiple bugs
2018-04-21 12:09:30 +02:00
Matthew Justin Bauer
6b11a5ff13
Merge pull request #38979 from xeji/tests-systemd
nixos/tests/systemd: fix broken test
2018-04-20 18:04:12 -05:00
aszlig
a9cd8ef23e
nixos/tests/containers-imperative: Fix eval
The commit c6f7d43678 changed the system
attribute to be below config.nixpkgs.localSystem, but the test still
uses the old attribute.

I have not tested whether the test actually succeeds but just checked
whether evaluation works and it evaluates successfully now.

Signed-off-by: aszlig <aszlig@nix.build>
2018-04-20 12:25:04 +02:00
xeji
9d5af5871d nixos/test/systemd: fix broken test
timing bug resulted in sporadic test failures on hydra
2018-04-16 00:43:33 +02:00
Daiderd Jordan
d538fc06e2
docker-tools: add a test for permissions issues with AUFS/overlay
docker# [   11.054736] d24d6cdd57c9[763]: /bin/bash: error while loading
shared libraries: libreadline.so.7: cannot open shared object file:
Permission denied
docker# /bin/bash: error while loading shared libraries:
libreadline.so.7: cannot open shared object file: Permission denied
docker: exit status 127
docker: output:
error: command `docker run --rm -u 1000:1000 bash /bin/bash --version'
did not succeed (exit code 127)
command `docker run --rm -u 1000:1000 bash /bin/bash --version' did not
succeed (exit code 127)
2018-04-14 14:11:14 +02:00
Tim Steinbach
0625f77256
Fix kernel-copperhead test 2018-04-13 09:02:26 -04:00
Florian Klink
fe840cd333 deluge: add test 2018-04-13 10:30:22 +02:00
Léo Gaspard
4fddb8b9c3
dovecot module: test dovecot's LDA
That's apparently not enough to catch the bug I ran into with the update
to 2.3.1, but at least it will check the LDA appears to work.
2018-04-12 01:35:14 +02:00
Michael Raskin
c78c764547 nixos/tests.chromium: actually notice the tab crash
Argh, debugging NixOS tests takes forever…

(cherry picked from commit 1afb6e790a)
2018-04-09 13:21:53 +02:00
Maximilian Bosch
50a34e55b2
nixos/iftop: add module
This patch is heavily inspired by bd0d8ed807 which added
a setcap wrapper for `mtr` in order to allow running `mtr` without
`sudo`. The need for the capability `cap_net_raw` that can be registered using
`setcap` has been documented in the Arch Wiki: https://wiki.archlinux.org/index.php/Capabilities#iftop

A simple testcase has been added which starts two machines, one with a
setcap wrapper for `iftop`, one without. Both testcases monitor the
bandwidth usage of the machine using the options `-t -s 1` once, the
machine with setcap wrapper is expected to succeed, the `iftop` on the
machine without setcap wrapper is expected to return a non-zero exit
code.
2018-04-07 15:06:51 +02:00
Corey O'Connor
d0d05024d1 nixos/transmission: add basic nixos test 2018-04-05 22:07:49 +02:00
Charles Strahan
5c066e2bba
Merge pull request #37218 from cstrahan/kube-test-fix
nixos: kubernetes fixes
2018-04-04 19:14:48 -04:00
Tuomas Tynkkynen
bbc80227ab nixos/tests/openldap: Fix name 2018-04-04 18:26:41 +03:00
Vladimír Čunát
75e4d3f2f0
nixos.tests.containers-imperative: fix impurity failure
I can't claim to fully understand this, but the change seems safe,
and it fixes the test on my machine.
2018-04-02 11:40:46 +02:00
Jörg Thalheim
0526d015b6 nixos/containers-physical_interfaces: use new bond option interface 2018-03-31 19:01:10 +01:00
Charles Strahan
709b6f664e
nixos: kubernetes fixes
* Fix reference CNI plugins
  * The plugins were split out of the upstream cni repo around version
    0.6.0

* Fix RBAC and DNS tests
  * Fix broken apiVersion fields
  * Change plugin linking to look in ${package}/bin rather than
    ${package.plugins}

* Initial work towards a working e2e test
  * Test still fails, but at least the expression evaluates now

Continues @srhb's work in #37199

Fixes #37199
2018-03-30 17:33:45 -04:00
Franz Pletz
9f3718fe1d
Merge pull request #37507 from xeji/p/test-atd
nixos/tests/atd : remove non-deterministic test of batch command
2018-03-28 06:31:50 +00:00
Tuomas Tynkkynen
d27f7942b7 nixos/tests/misc: Fix on aarch64
The psmouse module is for PS/2 mouse only, which doesn't exist outside
x86. But we can test for the mousedev module just as well which is used
for the '-device usb-tablet' emulated by QEMU.
2018-03-25 18:29:21 +03:00
Tuomas Tynkkynen
3131daace1 nixos/tests/installer: Give eval failure on unsupported boot methods 2018-03-24 16:11:31 +02:00
Matthew Justin Bauer
13051370a5
Merge pull request #36459 from NeQuissimus/zfh_openldap
openldap: Fix test
2018-03-23 14:32:43 -05:00
Robin Gloster
76ea0e1b2e
Merge pull request #32960 from florianjacob/prosody-0.10
Prosody 0.10.0
2018-03-22 14:12:57 +01: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
Florian Jacob
88f06c5ce9 nixos/prosody: add a basic test 2018-03-21 15:33:58 +01:00
xeji
b08560fb0a nixos/tests/atd : remove test of batch command
"batch" executes jobs based on system load.
test was not deterministic.
2018-03-21 00:58:41 +01:00
Robert Schütz
c484079ac7
Merge pull request #36927 from dotlambda/borg-module
nixos/borgbackup: init
2018-03-19 20:30:32 +01:00
Robert Schütz
fdf0f037be nixos/borgbackup: init 2018-03-19 13:12:47 +01:00
Tim Steinbach
3aa3738bb2 vault: Fix test 2018-03-18 19:15:56 +00:00
Tuomas Tynkkynen
ef64208eba Merge commit '3ab2949' from staging into master
Conflicts:
	pkgs/development/compilers/llvm/6/llvm.nix
	pkgs/servers/home-assistant/component-packages.nix
2018-03-15 22:30:56 +02:00
Graham Christensen
1a1abb383a
Merge pull request #36706 from Ma27/xautolock-testcase
xautolock: implement basic test to confirm functionality
2018-03-13 18:55:04 -04:00
Tuomas Tynkkynen
2fec9c6e29 Merge remote-tracking branch 'upstream/master' into staging
Conflicts:
	pkgs/development/tools/build-managers/conan/default.nix
2018-03-13 23:04:18 +02:00
aszlig
ba816ee087
nixos/tests/virtualbox: Work around test failures
I've started digging into the actual cause of the problem a week ago but
didn't continue fixing this.

The reason why the tests are failing is because
torvalds/linux/commit/72f5e08dbba2d01aa90b592cf76c378ea233b00b has
remapped the location of the TSS into the CPU entry area and we did
update our default kernel to version 4.14 in NixOS/nixpkgs@88530e02b6.

Back to VirtualBox: The guru meditation happens in
selmRCGuestTssPostWriteCheck, which I think is only a followup error. I
believe the right location couldn't be determined by VirtualBox and thus
the write check function triggers that panic because it's reading from
the wrong location.

So the actual problem *only* surfaces whenever we use software
virtualization, which we do for our tests because we don't have nested
virtualization available.

Our tests are also for testing the functionality of VirtualBox itself
and not certain kernel versions or kernel features, so for the time
being and until this is fixed, let's actually use kernel version 4.9 for
the guests within the VM tests. Kernel 4.9 didn't have the mentioned
change of the TSS location and thus the tests succeed.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @dtzWill
2018-03-13 22:00:56 +01:00
Maximilian Bosch
4f225f96d5
xautolock: implement basic test to confirm functionality 2018-03-13 21:04:44 +01:00
Antoine Eiche
bc1e8f95d4 tests/docker-tools: add onTopOfPulledImage test 2018-03-13 11:59:22 +01:00
WilliButz
ef90ff2d8e grafana: 5.0.0 -> 5.0.1 2018-03-12 23:37:29 +01:00
Franz Pletz
b0fa004fa9
nixos/tests/containers-tmpfs: fix test name 2018-03-12 22:28:27 +01:00
Jan Malakhovski
7079e744d4 Merge branch 'master' into staging
Resolved the following conflicts (by carefully applying patches from the both
branches since the fork point):

   pkgs/development/libraries/epoxy/default.nix
   pkgs/development/libraries/gtk+/3.x.nix
   pkgs/development/python-modules/asgiref/default.nix
   pkgs/development/python-modules/daphne/default.nix
   pkgs/os-specific/linux/systemd/default.nix
2018-03-10 20:38:13 +00:00
Sarah Brofeldt
df3706c47c nixos/tests/acme: use mail-test-srv tls certs from source 2018-03-08 22:50:26 +01:00
Sarah Brofeldt
bd35580860 nixos/tests/acme: go compat update, unvendor pkcs11 2018-03-08 22:50:26 +01:00
Tim Steinbach
5fbf9dbf9b
openldap: Fix test 2018-03-07 18:13:55 -05:00
aszlig
7f26c1b7fb
nixos/tests/keymap: Remove OCR-friendly SLiM theme
The test doesn't use OCR, so we actually don't need an OCR-friendly
theme here.

Signed-off-by: aszlig <aszlig@nix.build>
2018-03-06 04:25:53 +01:00
Franz Pletz
0f78afdf25
Merge pull request #32248 from awakesecurity/parnell/fetchdocker
Support fetching docker images from V2 registries
2018-03-04 17:10:27 +00:00
Vladimír Čunát
2069a2a002
Merge #35454: nixos/pump.io: remove 2018-03-04 10:49:25 +01:00
Jörg Thalheim
6749f6e26e
Merge pull request #36249 from Ekleog/openldap-module-declarative-contents
Openldap module declarative contents
2018-03-03 19:00:13 +00:00
Jörg Thalheim
b2acbe58b2 nixos/openldap: add test 2018-03-03 18:53:52 +00:00
Vladimír Čunát
b70c93f211
Merge branch 'master' into nix-2.0 2018-03-03 18:02:35 +01:00
aszlig
88530e02b6
systemd: Update to latest NixOS branch
Updated to the latest version of the nixos-v237 branch, which fixes two
things:

  * Make sure that systemd looks in /etc for configuration files.
    https://github.com/NixOS/systemd/pull/15
  * Fix handling of the x-initrd.mount option.
    https://github.com/NixOS/systemd/pull/16

I've added NixOS VM tests for both to ensure we won't run into
regressions. The newly added systemd test only tests for that and is by
no means exhaustive, but it's a start.

Personally I only wanted to fix the former issue, because that's the one
I've been debugging. After sending in a pull request for our systemd
fork (https://github.com/NixOS/systemd/pull/17) I got a notice from
@Mic92, that he already fixed this and his fix was even better as it's
even suitable for upstream (so we hopefully can drop that patch
someday).

The reason why the second one came in was simply because it has been
merged before the former, but I thought it would be a good idea to have
tests for that as well.

In addition I've removed the sysconfdir=$out/etc entry to make sure the
default (/etc) is used. Installing is still done to $out, because those
directories that were previously into sysconfdir now get into
factoryconfdir.

Quote from commit NixOS/systemd@98067cc806:

  By default systemd should read all its configuration from /etc.
  Therefore we rely on -Dsysconfdir=/etc in meson as default value.
  Unfortunately this would also lead to installation of systemd's own
  configuration files to `/etc` whereas we are limited to /nix/store. To
  counter that this commit introduces two new configuration variables
  `factoryconfdir` and `factorypkgconfdir` to install systemd's own
  configuration into nix store again, while having executables looking
  up files in /etc.

Tested this change against all of the NixOS VM tests we have in
nixos/release.nix. Between this change and its parent no new tests were
failing (although a lot of them were flaky).

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @Mic92, @tk-ecotelecom, @edolstra, @fpletz
Fixes: #35415
Fixes: #35268
2018-03-03 10:39:38 +01:00
Frederik Rietdijk
810dd0f984 Merge remote-tracking branch 'upstream/master' into HEAD 2018-03-01 20:00:42 +01:00
lejonet
565f22d27a nixos/ceph: init module (#35299)
All 5 daemon types can be enabled and configured through the module and the module both creates the ceph.conf required but also creates and enables specific services for each daemon, based on the systemd service files that upstream provides.
2018-03-01 11:47:13 +00:00
Tuomas Tynkkynen
b8b2225f6b Merge remote-tracking branch 'upstream/master' into staging 2018-03-01 06:09:20 +02:00
Shea Levy
4de72b90f3
nixos: nix.sshServe: Support ssh-ng. 2018-02-28 16:55:00 -05:00
Bas van Dijk
ee95cb8169 strongswan-swanctl: fix test 2018-02-28 11:44:00 +01:00
Bas van Dijk
bd24b3addd nixos: add the strongswan-swanctl service
The strongswan-swanctl systemd service starts charon-systemd. This implements a IKE daemon
very similar to charon, but it's specifically designed for use with systemd. It uses the
systemd libraries for a native integration.

Instead of using starter and an ipsec.conf based configuration, the daemon is directly
managed by systemd and configured with the swanctl configuration backend.

See: https://wiki.strongswan.org/projects/strongswan/wiki/Charon-systemd

Note that the strongswan.conf and swantctl.conf configuration files are automatically
generated based on NixOS options under services.strongswan-swanctl.strongswan and
services.strongswan-swanctl.swanctl respectively.
2018-02-28 10:41:54 +01: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
cc2eeef4ab
Fix installing the Nixpkgs channel on the installation media
And test that it got installed correctly.
2018-02-27 19:58:23 +01:00
Rodney Lorrimar
21dcead5f0
nixos/pump.io: remove
This would probably be better maintained in a separate repo as an
external NixOS module which gets imported into user's configuration.
2018-02-27 12:52:51 +00:00
Nikolay Amiantov
9c1c424e52 cups service: fix client sockets
Use systemd to create the directory for UNIX socket. Also use localhost instead
of 127.0.0.1 as is done in default cupsd.conf so that IPv6 is enabled when
available.
2018-02-23 18:51:39 +03:00
Nikolay Amiantov
cc52eff6c6 Revert "cups service: fix client sockets"
This reverts commit cf4c077343.
2018-02-23 18:47:43 +03:00
Nikolay Amiantov
cf4c077343 cups service: fix client sockets
Use systemd to create the directory for UNIX socket. Also use localhost instead
of 127.0.0.1 as is done in default cupsd.conf so that IPv6 is enabled when
available.
2018-02-23 18:43:51 +03:00
Frederik Rietdijk
d328ba753e
Merge pull request #35243 from FRidh/postgis
postgis: get rid of composableDerivation
2018-02-22 16:49:56 +00:00
Eelco Dolstra
d12c9911df
Merge remote-tracking branch 'origin/master' into nix-2.0 2018-02-22 17:28:51 +01:00
Vladimír Čunát
1cacfe357b
nixos.tests.boot-stage1: fix missing libelf 2018-02-22 04:04:49 +01:00
Jörg Thalheim
57ad5dc844
Merge pull request #35078 from Mic92/powerdns
powerdns: 4.0.5 -> 4.1.1
2018-02-20 21:49:41 +00:00
Frederik Rietdijk
b2f53c76f8 postgis: get rid of composableDerivation
In this change composableDerivation is removed in favor of
stdenv.mkDerivation.
2018-02-20 22:17:16 +01:00
Will Dietz
f32139cf78 nixos: Add basic test of novacomd 2018-02-20 11:03:49 -06:00
Michael Raskin
10b3f7d356
Merge pull request #27688 from rnhmjoj/routes
nixos/networking-interfaces: make static routes configurable
2018-02-19 14:12:58 +00:00
Vladimír Čunát
8b1cf100cd
Merge #35169: nixos/tests: fix ipv6 test failure 2018-02-19 11:38:16 +01:00
rnhmjoj
a1dc3abf90
nixos/tests: fix test failure due to preferTempAddress changes 2018-02-19 11:31:20 +01:00
Frederik Rietdijk
6e1c714c99
Merge pull request #35084 from dotlambda/home-assistant
nixos/home-assistant: test MQTT configuration
2018-02-18 16:08:56 +00:00
Robert Schütz
772b72a8d7 nixos/home-assistant: test MQTT configuration 2018-02-17 20:43:55 +01:00
rnhmjoj
edc4a1f3e7
nixos/tests: fix random failures of privacy test 2018-02-17 18:07:04 +01:00
Jörg Thalheim
ba27be7955 nixos/powerdns: add test 2018-02-17 16:43:41 +00:00
rnhmjoj
e239c1e582
nixos/tests: rename IP addresses/routes options 2018-02-17 14:57:07 +01:00
rnhmjoj
c1bed05e34
nixos/networking-interfaces: rename IP addresses/routes options 2018-02-17 14:01:24 +01:00
rnhmjoj
f41111c4da
nixos/tests: add test for static routes 2018-02-17 14:01:23 +01:00
Jörg Thalheim
431c004fbd
Merge pull request #35048 from nlewo/test.dockerTools
nixos.test.dockerTools: add more tests
2018-02-17 10:05:25 +00:00
Joachim F
7bf049a54c
Merge pull request #34492 from rnhmjoj/privacy
nixos/networking-interfaces: add preferTempAddress option
2018-02-17 08:41:23 +00:00
Antoine Eiche
f9bb73f4aa nixos.test.dockerTools: add more tests 2018-02-16 18:24:48 +01:00
Tim Steinbach
87559028ef
Merge pull request #33954 from kuznero/pr/kubernetes
kubernetes: 1.7.9 -> 1.9.1
2018-02-16 13:56:59 +00:00
Jan Tojnar
c6283e6e06
Merge pull request #32751 from jtojnar/fwupd-1.0.2
fwupd: 1.0.1 → 1.0.4
2018-02-15 01:18:38 +01:00
Jan Tojnar
201cc158cb
nixos/fwupd: add test 2018-02-15 01:11:13 +01:00
Jan Tojnar
9857545446
Merge pull request #34979 from jtojnar/gjs-1.50.4
gnome3.gjs: 1.50.2 → 1.50.4
2018-02-14 23:10:07 +01:00
Jan Tojnar
7713889556
nixos/gjs: add test 2018-02-14 22:43:59 +01:00
Sam Parkinson
16fa6f59f7
nixos/plotinus: add module to enable plotinus 2018-02-14 22:25:12 +01:00
Profpatsch
1545f9062e nixos/tests: add simple dockerTools test 2018-02-14 06:36:14 +01:00
Parnell Springmeyer
0a603ee165
Merge remote-tracking branch 'upstream/master' into parnell/fetchdocker 2018-02-13 17:28:45 -06:00
markuskowa
bf53dc68c2 nixos/rdma-core: add module for soft RoCE and test (#34607) 2018-02-10 07:52:03 +00:00
Franz Pletz
3748f3aac8
Merge pull request #32582 from Ma27/yabar-module
yabar: add module
2018-02-09 18:43:59 +00:00
symphorien
0146074560 nixos/tests: add predictable-interface-names.nix (#34305) 2018-02-09 18:40:39 +00:00
Andreas Rammhold
04051ee9d0
Merge pull request #34562 from griff/rspamd-workers
nixos/rspamd: worker configuration, socket activation and tests
2018-02-09 14:45:54 +01:00
Brian Olsen
908fc5e14b
nixos/rspamd: options for worker configuration and socket activation 2018-02-09 06:19:03 +01:00
Eelco Dolstra
f64a4af328
Fix comments 2018-02-07 19:32:41 +01:00
Eelco Dolstra
df117acab7
ISO images: Initialize the Nix database with correct NAR hashes/sizes
The boot test now runs "nix verify" to ensure that all hashes are
correct.
2018-02-07 16:54:23 +01:00
Eelco Dolstra
5193807750
VM tests: Initialize the Nix database with correct NAR hashes/sizes 2018-02-07 15:49:02 +01:00
David McFarland
e591f11c25 nixos/tests: add matrix-synapse test 2018-02-04 21:22:55 -04:00
Sarah Brofeldt
bf58890a5a nixos/k8s: Enable Node authorizer and NodeRestriction by default 2018-02-04 21:23:36 +01:00
Brian Olsen
27ee0b9099
nixos/tests: add basic tests for services.rspamd 2018-02-03 20:07:15 +01:00
Frederik Rietdijk
db58049f75
Merge pull request #34494 from dotlambda/home-assistant
home-assistant: compute extraComponents from config
2018-02-03 08:01:50 +00:00
aszlig
2a09b4275c
nixos/tests/make-test.nix: Fix eval error
Regression introduced by 943592f698.

The lib attribute isn't in scope here, so we need to use pkgs.lib
instead for isFunction.

Signed-off-by: aszlig <aszlig@nix.build>
Cc: @shlevy
2018-02-02 17:44:08 +01:00
Shea Levy
43f647e5b4
Merge branch 'dynamic-function-args' 2018-02-02 09:41:16 -05:00
Robert Schütz
78c2ca326e home-assistant: compute extraComponents from config 2018-02-02 09:48:50 +01:00
rnhmjoj
4050c30da2
nixos/tests: add test for temporary IPv6 addresses 2018-02-01 16:29:36 +01:00
Jörg Thalheim
57d72d4140
Merge pull request #34442 from rnhmjoj/virtual
Fix virtualType for network-interfaces-scripted
2018-02-01 10:35:13 +00:00
Frederik Rietdijk
d30735f889
Merge pull request #34188 from dotlambda/home-assistant
home-assistant: init at 0.62.1
2018-02-01 08:44:48 +00:00
Shea Levy
943592f698
Add setFunctionArgs lib function.
Among other things, this will allow *2nix tools to output plain data
while still being composable with the traditional
callPackage/.override interfaces.
2018-01-31 14:02:19 -05:00
Robert Schütz
0604c078a8 home-assistant: add NixOS test 2018-01-31 12:34:58 +01:00
rnhmjoj
f1cacaf97c
nixos/tests: add test for virtual interfaces 2018-01-31 05:52:22 +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
Jörg Thalheim
8a5f77ffbc nixos/borgbackup: add test
We had problems to get borg's own test suite running.
This test is intended to perform a quick smoke test to see whether we
have missed not any important dependency necessary to create backups
with borg.

tested with:

$ nix-build nixos/release.nix -A tests.borgbackup.x86_64-linux
2018-01-29 14:14:57 +00:00
Tuomas Tynkkynen
d085af7b7d nixos/tests: Fix statsd test evaluation
Fixes:

error: anonymous function at nixos/tests/statsd.nix:1:25 called with unexpected argument ‘system’, at nixos/tests/make-test.nix:5:41
2018-01-26 23:29:53 +02:00
Jörg Thalheim
dfa6a81a31
Merge pull request #33331 from cransom/netdata-module
netdata service: fix permissions for apps.plugin
2018-01-19 23:19:29 +00:00
Leon Schuermann
f297ddb5c9 sudo: define extra rules in Nix language (#33905) 2018-01-17 14:56:08 +00:00
Sarah Brofeldt
ee4e6ebbfa
Merge pull request #32822 from LumiGuide/elk6
ELK: 5.6.1 -> 5.6.5 & add ELK 6.1.0
2018-01-14 10:40:50 +01:00
Jörg Thalheim
91ec1f784a
Merge pull request #33755 from srhb/keymap-test-disable-xterm-dm
nixos/tests/keymap: disable xterm DM
2018-01-13 17:03:53 +00:00
Sarah Brofeldt
4488e7c435 nixos/tests/keymap: disable xterm DM 2018-01-11 20:12:49 +01:00
Parnell Springmeyer
e4ec980e9c
Merge remote-tracking branch 'upstream/master' into parnell/fetchdocker 2018-01-10 10:13:49 -08:00
rnhmjoj
4ebb9621f4
Revert "nixos/dnscrypt-proxy: remove"
This reverts commit 5dc2853981.
The project has a new maintainer.
2018-01-08 15:09:33 +01:00
Joachim Fasting
5dc2853981 nixos/dnscrypt-proxy: remove
The upstream project ceased.

See https://github.com/NixOS/nixpkgs/issues/33540
2018-01-07 17:00:32 +01:00
Maximilian Bosch
dbc414a8a5
yabar: add module
To make the configuration of `yabar` more pleasant and easier to
validate, a NixOS module will be quite helpful.

An example config could look like this:

```
{
  programs.yabar = {
    enable = true;
    bars.top.indicators.exec = "YA_DATE";
  };
}
```

The module adds a user-controlled systemd service which runs `yabar` after
starting up X.
2018-01-04 09:58:21 +01:00
Casey Ransom
f3cba4f6bb netdata service: fix permissions for apps.plugin
apps.plugin requires capabilities for full process monitoring. with
1.9.0, netdata allows multiple directories to search for plugins and the
setuid directory can be specified here.

the module is backwards compatible with older configs. a test is
included that verifies data gathering for the elevated privileges. one
additional attribute is added to make configuration more generic than
including configuration in string form.
2018-01-02 17:57:19 -05:00
Bas van Dijk
803077ef1c elk: add elasticsearch6, logstash6, kibana6 and the beats at v6.1.0
This change is backwards compatible since the ELK tools at version 5.x
remain unchanged.

The test suite now both tests ELK-5 and ELK-6.
2018-01-02 01:15:29 +01:00
Markus Kowalewski
b7fdefc8a4 beegfs: init at 6.17
package, kernel module, nixos module, and nixos test
2017-12-31 07:07:02 +00:00
Florian Klink
0543dc77b1 nixos/tests/virtualbox: remove mknod /dev/vda1 call
With devtmpfs introduced in 0d27df280f it is
created automatically.

See https://github.com/NixOS/nixpkgs/pull/32983#issuecomment-353703083
2017-12-23 03:16:18 +00:00
Jörg Thalheim
5687f61b19
Merge pull request #32637 from makefu/pkgs/openstack/nuke
nuke openstack (again)
2017-12-15 10:06:23 -08:00
makefu
71767ee3c7
glance: rip
part of openstack cleanup
2017-12-15 16:08:10 +01:00
makefu
d3d94992cf
keystone: rip
part of openstack cleanup
2017-12-15 16:06:44 +01:00
Franz Pletz
0f18f4af88
nixos/tests/jenkins: check if jenkins is available 2017-12-14 16:03:24 +01:00
Linus Heckemann
e4b32222a3 nixos/tests: correct comment in radicale.nix (#32574)
The secrets are in fact also stored unhashed, as part of the .drv file
which produces the htpasswd.
2017-12-11 22:09:23 +00:00
Peter Hoeg
e5715d9464 cups: 2.2.2 -> 2.2.6 2017-12-07 07:22:39 +00:00
Maximilian Bosch
af75b48b51 services.statsd: add simple test 2017-12-04 16:56:16 +01:00
Daiderd Jordan
6a20b88cec
vault: add nixos test 2017-12-04 12:59:52 +01:00
Parnell Springmeyer
6c9de3f600
hocker: Don't check package and wrap the binaries with PATH to nix 2017-12-02 09:20:22 -06:00
Parnell Springmeyer
c1eb962516
fetchdocker: Integration test exercising hocker and fetchdocker
This change adds a simple integration test exercising the fetchdocker
Nix code and hocker utilities for the simple `hello-world` docker
container. We exercise:

- Fetching the docker image configuration json
- Fetching the docker image layers
- Building a compositor script
- Loading the `hello-world` docker image into docker using the
  compositor script and `docker load`
- Running that loaded container
2017-12-01 21:06:16 -06:00
Tuomas Tynkkynen
dc5cd7800a tests/initrd-network-ssh: Don't build during evaluation
Issue #29774
2017-11-27 12:08:57 +02:00
Joachim F
822342ffdf
Merge pull request #31048 from LumiGuide/fix-owncloud
Fix some but not all errors in owncloud
2017-11-25 12:43:29 +00: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
obadz
edcf51a359
Merge pull request #31805 from gleber/make-switch-to-configuration-pure
nixos/system: make switch-to-configuration script pure
2017-11-19 19:03:52 +00:00
Franz Pletz
f367bb4d6d
Merge pull request #31569 from gleber/add-mutable-users-test
nixos/tests: add a test for config.users.mutableUsers.
2017-11-19 19:54:28 +01:00
Gleb Peregud
2f6148c743 nixos/system: make switch-to-configuration script pure.
Fixes #28443

Fixed few invocations to `systemctl` to have an absolute path. Additionally add
LOCALE_ARCHIVE so that perl stops spewing warning messages.
2017-11-19 19:42:54 +01:00
Gleb Peregud
1dd0379ba8 nixos/tests: Add a test for config.users.mutableUsers.
It's in preparation to add an assertion for #4990.
2017-11-19 19:11:19 +01:00
Franz Pletz
71b8437e2c
nixos/tests: add couchdb test 2017-11-19 17:39:36 +01:00
Franz Pletz
00056e76d0
nixos/tests/acme: update terms of service to fix test 2017-11-17 16:05:13 +01:00
Orivej Desh
963204e6ee
Merge pull request #31753 from mbld/show-ip
nixos-container: Make show-ip work together with ipv4 + netmask
2017-11-17 00:32:56 +00:00
Orivej Desh
f79e3e237f
Merge pull request #31618 from adisbladis/zfs-tests
Add basic ZFS tests
2017-11-16 20:00:16 +00:00
Martin Bornhold
25b71e18f5 nixos-container: Modify existing test to cover show-ip command
Modified the existing test to check that the 'nixos-container show-ip' command
can handle ipv4 addresses with submask in CIDR notation.
2017-11-16 20:25:45 +01:00
Parnell Springmeyer
cb11bf73a5 nixos/nghttpx: add module for the nghttpx proxy server (#31680)
* nghttpx: Add a new NixOS module for the nghttpx proxy server

This change also adds a global `uid` and `gid` for a `nghttpx` user
and group as well as an integration test.

* nixos/nghttpx: fix building manual
2017-11-16 18:21:02 +00:00
Tuomas Tynkkynen
cbccb1edf5
nixos installer tests: Add UEFI Grub test
Fixed merge conflict. Closes #22923.
2017-11-14 11:30:28 +01:00
adisbladis
59e4599723
Add basic ZFS tests 2017-11-14 14:34:19 +08:00
aszlig
f6ae3948bc
tests/boot-stage1: Fix build of kcanary module
In bfe9c928c1 the default kernel has been
updated to version 4.14 and the declarations for allow_signal() and
signal_pending() are no longer exposed via kthread.h, so let's actually
use the right header files.

I've added a condition for kernel 4.10 and upwards to include the
linux/sched/signal.h header file, because that got introduced in version
4.10. Even if the declaration would still reside in kthread.h (I haven't
checked) for version 4.10 it won't hurt and the compilation will still
succeed.

Tested against kernel 4.9 and 4.14 and the build now succeeds.

Signed-off-by: aszlig <aszlig@nix.build>
2017-11-14 04:36:19 +01:00
Sarah Brofeldt
58d07e2d6b php: Add nixos test to ensure php-pcre works in httpd 2017-11-12 08:05:27 +01:00
Sarah Brofeldt
294bb6daea nixos/tests/gitlab.nix: Unbreak config, still times out 2017-11-06 14:52:33 +01:00
Tim Steinbach
97f172a1d5
Merge pull request #31146 from NeQuissimus/kafka_updates
Kafka: Update + Tests
2017-11-04 11:06:32 -04:00
Bas van Dijk
c894327215 postage: replaced by pgmanage-10.0.2
postage is no longer maintained and has been replaced by the identical pgmanage. See:

https://github.com/workflowproducts/postage#postage-has-been-replaced-with-pgmanage

The following error is raised when a user enables the deprecated `services.postage.enable` option:

Failed assertions:
- services.postage is deprecated in favor of pgmanage. They have the same options so just substitute postage for pgmanage.
2017-11-03 00:14:00 +01:00
Tim Steinbach
beefaff2c1
kafka: Add tests 2017-11-02 15:10:33 -04:00
Tim Steinbach
d27cf320cf
zookeeper: Add simple test 2017-11-02 14:09:56 -04:00
Bas van Dijk
cb4b9b1cc1 owncloud: fix some but not all errors
* Don't set timezone when it's null

* Don't create the postgres role because the postgresqsl service
  already does that.

* Fix documentation

* Add a test suite
2017-10-31 23:03:33 +01:00
Bas van Dijk
04b2460eb6 graphite: fix the graphiteApi service 2017-10-31 15:49:59 +01:00
Tuomas Tynkkynen
2f3786e7ef nixos/tests/gitolite: Don't build during evaluation
Noticed in https://hydra.nixos.org/jobset/nixos/release-17.09#tabs-errors:

````
hydra-eval-jobs returned exit code 1:
building path(s) '/nix/store/wxcbjli7m98yymnxrxkf6pigr7a05zad-id_ed25519.pub'
building '/nix/store/gyig2d7cry98647h0grfilq26cpc1wy8-id_ed25519.pub.drv'...
````

Issue #29774
2017-10-21 23:45:37 +03:00
Peter Simons
757a759005 Merge pull request #30166 from LumiGuide/graphite-1.0.2
Fix graphite crash by upgrading from 0.9.15 -> 1.0.2
2017-10-18 12:58:55 +01:00
Bjørn Forsman
774d05878a nixos/tests: unbreak prometheus test
Commit 271d3f7a43 ("prometheus service: globalConfig.labels is obsolete")
removed globalConfig.labels. Update the test config accordingly.
2017-10-16 20:31:49 +02:00
Bjørn Forsman
10e79d43f6 nixos/tests: add gitolite test 2017-10-16 19:22:07 +02:00
Bjørn Forsman
943730ff9b nixos/tests: add basic test for services.atd 2017-10-16 19:08:19 +02: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
Lancelot SIX
4ea954477f Merge pull request #30321 from RemiDesgrange/add-postgis-2.4.0
Add postgis 2.4.0
2017-10-14 10:13:53 +02:00
Rémi Desgrange
8dcaa5b313 postgis: add v2.4.0
Add postgis 2.4.0

doesn't remove v2.3.1. There are some big change in 2.4 that people may
don't want. see https://postgis.net/docs/release_notes.html#idm41021

fix test call

modify following recommandation of lsix
2017-10-13 09:45:25 +02:00
aszlig
20487112ed
nixos: Fix output path generation of runInMachine
Regression introduced by a02bb00156.

The fix is done by disabling writableStore, because the latter will set
up an overlayfs on the Nix store within the VM, which in turn will
discard all the outputs of the resulting output path.

However in runInMachine we actually *want* the contents of the generated
path and also don't want a writable store within the VM (except of
course for $out, which is writable anyway).

I've added a small regression test to verifify the output in
nixos/tests/run-in-machine.nix to make sure this won't break again in
the future.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-10-11 20:08:11 +02:00
Jörg Thalheim
62922af208 Merge pull request #29994 from bachp/minio-update
minio: 20170613 -> 2017-09-29T19-16-56Z
2017-10-08 12:12:32 +01:00
Pascal Bach
1983e6c8cc minio: 20170613 -> 2017-09-29T19-16-56Z
The test was updated as minio now needs at least 1 GiB of free disk,
otherwise it won't start.
2017-10-08 12:24:29 +02:00
Bas van Dijk
5b8ff5ed49 graphite: 0.9.15 -> 1.0.2
Fixes: #29961

Also added the option:

  services.graphite.web.extraConfig

for configuring graphite_web.
2017-10-08 03:03:22 +02:00
WilliButz
3539e16cfa
nixos/tests: clean up pgjwt test
- removed unneeded initscript
- use default postgres version for the test
2017-10-04 13:04:49 +02:00
Joachim F
0625110d1a Merge pull request #29927 from WilliButz/fix-pgjwt-test
nixos/tests: fix pgjwt test
2017-10-04 10:57:43 +00:00
Ruben Maher
06e15e59f9 nixos/krb5: complete rewrite
The `krb5` service was a bit lacking.

Addresses NixOS/nixpkgs#11268, partially addresses NixOS/nixpkgs#29623.
2017-10-02 14:30:19 +10:30
WilliButz
7d09fc6ea7
nixos/tests: rewrite pgjwt test
- now using the test contained in the pgjwt source repo
- also compatible with the new `superUser` option of the
  `postgresql` service
2017-10-01 20:12:58 +02:00
Jan Tojnar
dfdfb97f0f nixos/tests/gnome3-gdm: Increase memory limit
The test was failing on x86_64 prematurely due to memory being exhausted.

See also 3b9f0c6a46
2017-09-28 17:20:23 +02:00
Robin Gloster
d05b0b6b70
mesos test: fix python handling
Still does not succeed but advances further

(cherry picked from commit 30d09f717aa94a78105bff22da548b904887b394)
2017-09-28 01:15:41 +02:00
Rodney Lorrimar
56eba66f77 mysqlBackup service: let it work with default settings
* Grants enough privileges to the configured user so that it can run
  mysqldump.

* Adds a nixos test.

* Use systemd timers instead of a cronjob (by @fadenb).

* Creates a new user for backups by default, instead of using mysql
  user.

* Ensures that backup user has write permissions on backup location.

* Write backup to a temporary file before renaming so that a failed
  backup won't overwrite the previous backup, and so that the backup
  location will never contain a partial backup.

Breaking changes:

 * Renamed period to calendar to reflect the change in how to
   configure the backup time.

 * A failed backup will no longer result in cron sending an e-mail --
   users' monitoring systems must be updated.

Resolves #24728
2017-09-27 18:44:49 +02:00
Silvan Mosberger
a8c97ad23e nixos/radicale: fix default version (#29743) 2017-09-25 10:18:42 +00:00
Matej Cotman
6ef8cad2a7 kubernetes: fix tests 2017-09-24 11:44:25 +02:00
Jaka Hudoklin
7dfeac88ac kubernetes module: flannel support, minor fixes
- add flannel support
- remove deprecated authorizationRBACSuperAdmin option
- rename from deprecated poratalNet to serviceClusterIpRange
- add nodeIp option for kubelet
- kubelet, add br_netfilter to kernelModules
- enable firewall by default
- enable dns by default on node and on master
- disable iptables for docker by default on nodes
- dns, restart on failure
- update tests

and other minor changes
2017-09-24 11:44:25 +02:00
Matej Cotman
8e14e978c8 kubernetes: fix minor issues 2017-09-24 11:44:25 +02:00
Matej Cotman
7f9d1a7aaf kubernetes: add tests 2017-09-24 11:44:25 +02:00
Joachim Fasting
bccaf63067
nixos/hardened test: add failing test-case for deferred mounts 2017-09-22 23:53:27 +02:00
aszlig
a75265924f
nixos/tests/virtualbox: Fix netcat invocation
This is a backwards-incompatibility in netcat-openbsd introduced due to
bumping the netcat version to 1.130 in
a72ba661ac.

Version 1.130 no longer exits on EOF but now needs to be passed the -N
flag in order to exit on EOF.

The upstream change reads[1] like this:

  Don't shutdown nc(1)'s network socket when stdin closes. Matches
  *Hobbit*'s original netcat and GNU netcat; revert to old behaviour
  with the new -N flag if needed. After much discussion with otto
  deraadt tedu and Martin Pelikan.  ok deraadt@

Here is the diff of this change:

http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/nc/netcat.c.diff?r1=1.110&r2=1.111&f=h

[1]: http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/nc/netcat.c?rev=1.111&content-type=text/x-cvsweb-markup

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-09-21 03:49:46 +02:00
Franz Pletz
406c7a0731 Merge pull request #29521 from aneeshusa/ease-radicale-upgrade
Ease radicale upgrade
2017-09-18 23:13:53 +02:00
WilliButz
9198ad65ef tests: add initrd-network-ssh test
starts two VMs:
- one with dropbear listening from initrd,
  waiting for a file
- another connecting via ssh, creating the file
2017-09-18 19:51:46 +02:00
Aneesh Agrawal
28c2cea847 radicale: Test migration functionality
This also provides an example of how to migrate.
2017-09-18 09:11:36 -07:00
WilliButz
0b2d9bbbd2 nixos/tests: add grafana test (#29531) 2017-09-18 16:59:50 +02:00
Franz Pletz
b179908414
nixos/networking: network is online if default gw set
Previously services depending on network-online.target would wait until
dhcpcd times out if it was enabled and a static network address
configuration was used. Setting the default gateway statically is enough
for the networking to be considered online.

This also adjusts the relevant networking tests to wait for
network-online.target instead of just network.target.
2017-09-18 14:51:38 +02:00
Maximilian Güntner
44475cae27 tests: ipfs: enable autoMount tests 2017-09-18 00:05:35 -07:00
aszlig
3ba2095a42
nixos/dovecot: Fix createMailUser implementation
This option got introduced in 7904499542
and it didn't check whether mailUser and mailGroup are null, which they
are by default.

Now we're only creating the user if createMailUser is set in conjunction
with mailUser and the group if mailGroup is set as well.

I've added a NixOS VM test so that we can verify whether dovecot works
without any additional options set, so it serves as a regression test
for issue #29466 and other issues that might come up with future changes
to the Dovecot service.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Fixes: #29466
Cc: @qknight, @abbradar, @ixmatus, @siddharthist
2017-09-17 04:57:20 +02:00
Joachim F
8ceb209830 Merge pull request #29462 from joachifm/trivial-misc-tests
nixos/tests: move kernel-params & sysctl test to misc
2017-09-16 19:51:58 +00:00
Joachim Fasting
586d04c588
nixos/tests: expand hardened tests 2017-09-16 13:14:07 +02:00
Joachim Fasting
ffd56ba4f6
nixos/tests: move kernel-params test to misc 2017-09-16 12:45:28 +02:00
Joachim Fasting
c85cf60c83
nixos/tests: move sysctl test to misc 2017-09-16 12:45:23 +02:00
aszlig
b5fbb4f362
nixos/tests/acme: Use overridePythonAttrs
Quoting from @FRidh:

  Note overridePythonAttrs exists since 17.09. It overrides the call to
  buildPythonPackage.

While it's not strictly necessary to do this, because postPatch ends up
in drvAttrs anyway, it's probably better to use overridePythonAttrs so
we don't run into problems when the underlying implementation of
buildPythonPackage changes.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-09-14 23:18:52 +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
aszlig
01fffd94e5
nixos/tests/acme: Patch certifi with cacert
Since 67651d80bc the requests package now
depends on certifi, which in turn provides the CA root certificates that
we need to replace.

It might also be a good idea to actually patch certifi with our version
of cacert by default so that if we want to override and/or add something
we only need to do it once.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Cc: @fpletz, @k0ral, @FRidh
2017-09-13 23:16:43 +02:00
aszlig
bda38317eb
nixos/tests/letsencrypt: Fix nginx options
The enableSSL option has been deprecated in
a912a6a291, so we switch to using onlySSL.

I've also explicitly disabled enableACME, because this is the default
and we don't actually want to have ACME enabled for a host which runs an
actual ACME server.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-09-13 23:16:40 +02:00
aszlig
11b3ae74e1
nixos/tests: Add a basic test for ACME
The test here is pretty basic and only tests nginx, but it should get us
started to write tests for different webservers and different ACME
implementations.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-09-13 23:16:37 +02:00
aszlig
b3162a1074
nixos/tests: Add common modules for letsencrypt
These modules implement a way to test ACME based on a test instance of
Letsencrypt's Boulder service. The service implementation is in
letsencrypt.nix and the second module (resolver.nix) is a support-module
for the former, but can also be used for tests not involving ACME.

The second module provides a DNS server which hosts a root zone
containing all the zones and /etc/hosts entries (except loopback) in the
entire test network, so this can be very useful for other modules that
need DNS resolution.

Originally, I wrote these modules for the Headcounter deployment, but
I've refactored them a bit to be generally useful to NixOS users. The
original implementation can be found here:

https://github.com/headcounter/deployment/tree/89e7feafb/modules/testing

Quoting parts from the commit message of the initial implementation of
the Letsencrypt module in headcounter/deployment@95dfb31110:

    This module is going to be used for tests where we need to
    impersonate an ACME service such as the one from Letsencrypt within
    VM tests, which is the reason why this module is a bit ugly (I only
    care if it's working not if it's beautiful).

    While the module isn't used anywhere, it will serve as a pluggable
    module for testing whether ACME works properly to fetch certificates
    and also as a replacement for our snakeoil certificate generator.

Also quoting parts of the commit where I have refactored the same module
in headcounter/deployment@85fa481b34:

    Now we have a fully pluggable module which automatically discovers
    in which network it's used via the nodes attribute.

    The test environment of Boulder used "dns-test-srv", which is a fake
    DNS server that's resolving almost everything to 127.0.0.1. On our
    setup this is not useful, so instead we're now running a local BIND
    name server which has a fake root zone and uses the mentioned node
    attribute to automatically discover other zones in the network of
    machines and generate delegations from the root zone to the
    respective zones with the primaryIPAddress of the node.

    ...

    We want to use real letsencrypt.org FQDNs here, so we can't get away
    with the snakeoil test certificates from the upstream project but
    now roll our own.

    This not only has the benefit that we can easily pass the snakeoil
    certificate to other nodes, but we can (and do) also use it for an
    nginx proxy that's now serving HTTPS for the Boulder web front end.

The Headcounter deployment tests are simulating a production scenario
with real IPs and nameservers so it won't need to rely on
networking.extraHost. However in this implementation we don't
necessarily want to do that, so I've added auto-discovery of
networking.extraHosts in the resolver module.

Another change here is that the letsencrypt module now falls back to
using a local resolver, the Headcounter implementation on the other hand
always required to add an extra test node which serves as a resolver.

I could have squashed both modules into the final ACME test, but that
would make it not very reusable, so that's the main reason why I put
these modules in tests/common.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-09-13 23:16:33 +02:00
Tim Steinbach
84e34d4d5d
tests: xmonad less dependent on timings 2017-09-09 10:07:34 -04:00
Tim Steinbach
024b501907
tests: Fix hibernate 2017-09-06 22:01:48 -04:00
Tim Steinbach
7faad2dce8 Merge pull request #29040 from NeQuissimus/tests_sys
More basic system tests
2017-09-06 15:04:10 -04:00
Tim Steinbach
a54b2e3ba2 Merge pull request #29002 from NeQuissimus/docker_edge_module_test
docker: Package in module, tests
2017-09-06 15:03:56 -04:00
Tim Steinbach
0857e4c84d Merge pull request #28989 from NeQuissimus/tests_xmonad
Add XMonad test
2017-09-06 15:03:41 -04:00
Tim Steinbach
b4ccef2163
tests: Add environment 2017-09-05 19:05:37 -04:00
Tim Steinbach
3e2975e892
tests: Add kernelParams 2017-09-05 19:04:43 -04:00
Tim Steinbach
04b0f3255f
tests: Add sysctl 2017-09-05 19:03:54 -04:00
Franz Pletz
1bed4773f5
postgresql92: remove last references 2017-09-05 18:20:56 +02:00
Jörg Thalheim
3558ed8bfd Merge pull request #28988 from NeQuissimus/tests_kernel_basic
Add basic kernel tests
2017-09-05 16:38:50 +01:00
Tim Steinbach
656ec9de0e
Add basic kernel tests 2017-09-05 10:38:07 -04:00
Tim Steinbach
380ed98bd7
docker: Add test for docker-edge, check for proper versions in tests 2017-09-04 19:02:44 -04:00
Michele Catalano
4ea1d49643 nexus: Add module for nexus.
Add also myself as maintainer
Add simple test of the nexus service
2017-09-04 22:32:02 +02:00
Tim Steinbach
e153fa84a5
Add XMonad test 2017-09-04 14:03:20 -04:00
Philipp Steinpass
d784b83005 nixos/hydra postgresql: Fix #27314 and add test case 2017-09-02 23:07:42 +02:00
Jan Tojnar
3b9f0c6a46
gnome3 tests: fix by providing more memory
/cc #28053.
2017-09-01 07:51:05 +02:00
Vladimír Čunát
6b95cf646c
Merge: fixups to staging merge
None are large rebuilds; most are on staging already.
2017-08-30 21:17:17 +02:00
Franz Pletz
e3a8f58a21 Merge pull request #28746 from mguentner/ipfstest
tests: fix ipfs test, test actual networking functionality
2017-08-30 18:50:40 +02:00
Maximilian Güntner
a1302eab3a
tests: fix ipfs test, test actual networking functionality 2017-08-30 15:28:50 +02:00
Franz Pletz
7d1d019650 Merge pull request #27826 from Infinisil/radicale
radicale: update to version 2
2017-08-30 02:17:34 +02:00
Franz Pletz
3e18f32f68 Merge pull request #28465 from danbst/reloadable-containers
Reloadable containers
2017-08-30 02:01:46 +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
danbst
63f8122cd9 nixos tests: add test for declarative containers, that container config changes
are applied on `nixos-rebuild switch` invocations.
2017-08-23 12:43:07 +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
Silvan Mosberger
e16a0988bc
radicale: 1.1.4 -> 2.1.2
This commit readds and updates the 1.x package from 1.1.4 to 1.1.6 which
also includes the needed command for migrating to 2.x

The module is adjusted to the version change, defaulting to radicale2 if
stateVersion >= 17.09 and radicale1 otherwise. It also now uses
ExecStart instead of the script service attribute. Some missing dots at
the end of sentences were also added.

I added a paragraph in the release notes on how to update to a newer
version.
2017-08-13 17:23:43 +02:00
Franz Pletz
59fa868b01
tests.plasma5: fix hash 2017-08-12 00:55:32 +02:00
Robin Gloster
350a6c3726
tests.plasma5: fix eval 2017-08-11 21:53:17 +02:00
Franz Pletz
9f7f85a3cd
nixos/tests/nginx: fix name 2017-08-11 17:37:14 +02:00
Robin Gloster
b18b70c74d
nixos.tests.nat: fix 2017-08-04 17:52:42 +02:00
Markus Mueller
1793c96be2
tests/nat: Use switch-to-configuration in test case 2017-08-03 21:16:14 +02:00
Linus Heckemann
a0d464033c nixos/timezone: support imperative timezone configuration (#26608)
Fixes #26469.
2017-07-31 15:55:24 +01:00
Frederik Rietdijk
29f91c107f Merge remote-tracking branch 'upstream/master' into HEAD 2017-07-23 11:23:43 +02:00
Thomas Tuegel
4b14212914
nixos/tests/keymap: use SLIM theme from nixos/tests/slim 2017-07-22 17:43:28 -05:00
Franz Pletz
226964861f Merge pull request #27405 from rvl/postgresql-xml
postgresql: fix nixos tests and add xml support
2017-07-20 20:31:38 +02:00
Rodney Lorrimar
0b027720af nixos tests: run postgresql tests with postgres user 2017-07-19 22:13:02 +01:00
aszlig
b618843860
nixos/taskserver: Fix manual PKI management
The helper tool had a very early check whether the automatically created
CA key/cert are available and thus it would abort if the key was
unavailable even though we don't need or even want to have the CA key.

Unfortunately our NixOS test didn't catch this, because it was just
switching from a configuration with an automatically created CA to a
manual configuration without deleting the generated keys and certs.

This is done now in the tests and it's also fixed in the helper tool.

Reported-by: @jpotier
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-07-16 20:38:15 +02:00
Christian Kögler
e8a8f1233a snapper: add nixos module
fixes #27154
2017-07-16 10:06:42 +01:00
Rodney Lorrimar
502a272ee7 postgresql: enable XML functions
I suspect these functions aren't widely used, but they are enabled in
PostgreSQL on Ubuntu and Arch.
2017-07-15 14:58:17 +01:00
Rodney Lorrimar
39ef4d2fe9 nixos tests: fix postgresql tests
1. Needs to call makeTest or else nothing happens when you run
   `nix-build nixos/tests/postgresql.nix`.

2. Tests run as root, so there needs to be a corresponding user in
   PostgreSQL.
2017-07-15 14:54:42 +01:00
Vladimír Čunát
0be14a588f
nixos tests.misc: unblock a man-page test
I'm not sure what's wrong, but the pages look OK.  Discussion:
https://github.com/NixOS/nixpkgs/pull/27061#issuecomment-314330032
2017-07-11 08:55:55 +02:00
Pascal Bach
0fb8456b13 minio service: add additional config options
Set access and secret key and disable browser.
Tests extended to do real operations against minio.
2017-07-09 15:19:50 +02:00
Tim Steinbach
fbbf926ce9
ammonite: add test 2017-07-04 21:36:30 -04:00
Graham Christensen
b0a4c2c33f
nixos: installer.nix test: test ZFS install use case 2017-06-28 19:45:20 -04:00
Pascal Bach
aa66c9ad37 minio service: add inital service
features:
- change listen port and address
- configure config and data directory
- basic test to check if minio server starts
2017-06-26 04:07:37 +02:00
aszlig
bcaf2f6dbe
nixos/tests/sddm: Fix detecting login screen
Tesseract seems to have a hard time detecting the "ALICE FOOBAR" text,
so let's match on "Select your user and enter password" instead.

Ran the test on x86_64-linux and it now succeeds.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-06-22 06:26:08 +02:00
Joachim F
631ec734eb Merge pull request #26460 from romildo/fix.nixos-artwork
nixos-artwork: add more wallpapers
2017-06-13 23:20:52 +01:00
Bas van Dijk
2444eab485 ELK: update kibana and the elastic beats to 5.4 (#26252)
* Add kibana5 and logstash5
* Upgrade the elastic beats to 5.4
* Make sure all elastic products use the same version
  (see elk5Version)
* Add a test for the ELK stack
2017-06-13 22:36:08 +02: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
Graham Christensen
225a230716 Merge pull request #23173 from nlewo/test/cloudinit
Cloudinit test
2017-06-05 18:34:06 -04:00
montag451
f0ca6f9290 nixos/tests: add tests for the LDAP stack 2017-05-27 02:51:46 +02:00
Vladimír Čunát
bba5b1c434
plasma5 tests: fix by using older fontconfig-penultimate
enable = false; didn't help, but downgrading did.  It's a mystery to me.
Discussion: https://github.com/NixOS/nixpkgs/commit/c9f8fb4d127a
2017-05-24 14:56:43 +02:00
Antoine Eiche
7b80f4c344 nixos/cloudinit: add cloudinit test
An iso containing metadatas is created and attached as a cdrom to the
qemu VM used for this test.

The cloudinit service is enabled. The test case ensures the root
authorized_keys file is populated and the cloudinit write_file module is
working well.
2017-05-23 20:51:05 +02: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
Frederik Rietdijk
9e48fc3268 Merge pull request #24131 from nand0p/buildbot-0.9.5
buildbot: 0.9.4 -> 0.9.5
2017-05-03 07:56:29 +02:00
Michael Raskin
1c8d388201 Merge pull request #23865 from volth/xrdp-tests
xrdp: init at 0.9.2
2017-04-30 22:35:48 +02:00
Michael Raskin
929ae39dbe Merge pull request #22683 from aneeshusa/add-nixos-test-for-radicale
Add nixos test for radicale
2017-04-30 18:51:46 +02:00
Joachim Fasting
a1678269f9
nixos/hardened profile: disable user namespaces at runtime 2017-04-30 15:17:27 +02:00
Joachim Fasting
ffa83edf4a
nixos/tests: add tests for exercising various hardening features
This test exercises the linux_hardened kernel along with the various
hardening features (enabled via the hardened profile).

Move hidepid test from misc, so that misc can go back to testing a vanilla
configuration.
2017-04-30 12:05:42 +02:00
Joachim Fasting
ab4fa1cce4
tree-wide: prune some dead grsec leaves
The beginning of pruning grsecurity/PaX from the tree.
2017-04-30 12:05:41 +02:00
volth
dad760061e xrdp: init at 0.9.1 2017-04-29 17:23:35 +00:00
Graham Christensen
5dd731b801
mysql test: test replication persists between slave stop / start cycle 2017-04-25 18:51:49 -04:00
Graham Christensen
da0ef84c0c
mysql test: use OpenPort check over blind sleep 2017-04-25 18:51:46 -04:00
aszlig
dc87b5587e
nixos: Add a VM test for the SLiM display manager
This is currently our default display manager, so I'm adding this to the
"tested" job as well to ensure we don't ship broken revisions where X is
most likely not working.

The test uses a custom SLiM theme that's specifically tailored for good
OCR results (mainly white background and black fonts without anything
else), because our default NixOS theme has a very small contrast between
background and fonts in some places.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-04-23 19:25:27 +02:00
Joachim Fasting
1b3300bf01
nixos/tests/misc: check hidepid mount via /proc/mounts 2017-04-23 11:00:46 +02:00
Fernando J Pando
4ac06ea6a1 buildbot: 0.9.4 -> 0.9.5
- adds distro dependency
- buildbot nodaemon in service module
- fakerepo for module tests
- service module parameter fixup
- tested on nixos
- tested on darwin
2017-04-21 10:32:36 -04: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
aszlig
5d5c0d590f
Revert "sddm: Fix test."
This reverts commit 0a6a06346a.

The commit replaced the text to search for from ALICE to BOB, because
our OCR detection only caught "BOB FOOBAR" but missed "ALICE FOOBAR"
completely.

With the improvements to our OCR system this no longer is the case and
the test passes successfully with this reverted.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Cc: @shlevy
2017-04-11 03:21:58 +02:00
Aneesh Agrawal
8f4d778509 radicale: Add aneeshusa as maintainer 2017-04-10 20:04:17 -04:00
Aneesh Agrawal
a3143b18e0 radicale: Also run NixOS test on Python 3 2017-04-10 20:04:17 -04:00
Aneesh Agrawal
189479a4ba radicale: Add NixOS test with Python 2
Includes testing bcrypt authentication.
2017-04-10 20:04:17 -04:00
Tomasz Czyż
e57cf5efd1 Merge branch 'master' into postgresql-tests 2017-04-07 10:28:58 +01:00
Shea Levy
0a6a06346a sddm: Fix test.
For whatever reason, the OCR code is not detecting ALICE but is BOB.

OCR output from login screen (blank lines omitted):

> Session none + icewm
> 08:41 <
> Thursday, April 6, 2017
> BOB FOOBAR
> Select your user and enter password
2017-04-06 04:44:47 -04:00
Graham Christensen
c7453084ef
docker: test for socket permissions 2017-04-03 09:05:41 -04:00
Tuomas Tynkkynen
affce1e246 nixos hibernate test: Use waitForOpenPort
There was one confusing recent failure of this:

http://cache.nixos.org/log/myla8bc17j8spmifdxmrz9jswxwsf5w6-vm-test-run-hibernate.drv

I don't have any real ideas on what could cause the problem but there is
at least one theoretical one: the system starts hibernating before the
listener process manages to open the TCP port for listening, and it can't
open it after resuming because not enough pages from the netcat binary
have been paged in (and as the 9p filesystem holding it is now toast,
they can't be loaded anymore).
2017-04-02 02:33:21 +03:00
Robin Gloster
ce953d0bc9
panomatic: remove 2017-03-30 16:23:33 +02:00
Joachim Fasting
543f5263d2
nixos/dnscrypt-proxy test: exercise plugin loading 2017-03-30 13:36:06 +02:00
aszlig
ee39d4b98a
nixos/tests/virtualbox: Fix @shell@ expansion
This has surfaced since f803270b7e.

The commit bumped bash to version 4.4, which caused to change the order
of --subst-var flags in substituteAll, which this test was relying on,
because it added a @shell@ to boot.initrd.postMountCommands.

Our substituter is currently working a bit like this:

original.replace('@var1@', 'val1').replace('@var2@', 'val2')...

Unfortunately, this means that if @var2@ occurs within @var1@ it is
replaced by the new value, so the order of the substvars actually
matter. I highly doubt that we want a behaviour like this and I'm
wondering why it didn't occur to me as a problem while writing the
initial implementation of the VirtualBox tests.

Whether to get rid of this and disallowing substitution of substvars
within substvars is another topic which I think needs discussion in a
different place.

As for now, I'm using stdenv.shell, because the closure size of this
should fit within the initrd, so it's fine especially because it's just
a test.

Tested with the net-hostonlyif and systemd-detect-virt tests and they
both succeed with this change.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Reported-by: @globin on IRC
2017-03-27 04:53:17 +02:00
Arnold Krille
68729958e8
network-interfaces: reload bridges on conf changes
And adopt the tests to add an interface and remove it again.

It should work when deactivating rstp, it will not work when activating
rstp for the first bridge as then the userspace daemon is not yet
available. But once one bridge is active with stp, it should work with
the reload for any further bridge.

Fixes #21745. Also see #22547.
2017-03-26 18:47:43 +02:00
Thomas Tuegel
352e335f3d
nixos/sddm: test automatic and manual login 2017-03-24 10:39:13 -05:00
Thomas Tuegel
27ba56f1e0
nixos/plasma5: also test SDDM theme 2017-03-24 09:45:57 -05:00
Thomas Tuegel
ae1034ea96
nixos/sddm: improve test
Disable SDDM auto-login to improve testing for SDDM themes. See #24246.
2017-03-23 19:20:27 -05:00
Jörg Thalheim
b4169bb8dd
munin: fix tests by replacing cron with systemd timer 2017-03-22 00:16:36 +01:00
Franz Pletz
fff8cc79df Merge pull request #23279 from mbbx6spp/make-nginx-module-less-gross
nginx service: add commonHttpConfig option
2017-03-20 19:03:20 +01:00
Michael Raskin
14a3412048 nixos: tests: firefox: make more comprehensive
Run Firefox inside an XTerm, it doesn't crash mysteriously this way.
Also try opening developer tools and checking that Firefox doesn't
crash in the process.
2017-03-15 17:25:57 +01:00
Bas van Dijk
308c09d41f wordpress: security upgrade: 4.7.2 -> 4.7.3 & other improvements (#23837)
* Moved the wordpress sources derivation to the attribute pkgs.wordpress. This
  makes it easier to override.

* Also introduce the `package` option for the wordpress virtual host config which
  defaults to pkgs.wordpress.

* Also fixed the test in nixos/tests/wordpress.nix.
2017-03-14 16:11:51 +01:00
Jörg Thalheim
41625dcab6
pump.io: fix tests
fixes #23568
2017-03-12 16:01:07 +01:00
Profpatsch
22c265182f networking/bonds: fix examples
After the change of the bonding options, the examples were not quite correct.
The diff is over-the top because the new `let` needs everything indented.

Also add a small docstring to the `networkd` attr in the networking test.
2017-03-08 04:54:17 +01:00
Fernando J Pando
9f062c2c0b buildbot: 0.9.3 -> 0.9.4
- adds jwt
- adds module tests
- master.cfg as path in module
- fix systemd worker config
- builds on darwin
- tested on nixos
2017-03-07 00:45:37 +01:00
Joachim Schiele
f8ad48ea1d nixos/tests/leaps.nix: fixed race condition 2017-03-06 21:33:21 +01:00
Thomas Tuegel
60817e4715
nixos/tests/trac: fix renaming warning 2017-03-03 07:26:51 -06:00
Thomas Tuegel
e7b0b2bb66
nixos/tests/phabricator: fix renaming warning 2017-03-03 07:26:17 -06:00
Thomas Tuegel
dcee54c935
nixos/tests/plasma5: fix test name 2017-03-03 07:25:45 -06:00
Thomas Tuegel
0da421ce17
nixos/tests: fix Plasma 5 test 2017-03-02 07:01:42 -06:00
Nikolay Amiantov
a6c6d08430 samba test: fix race condition 2017-03-01 03:16:35 +03:00
Susan Potter
251b9ca0e7
nginx service: add commonHttpConfig option 2017-02-28 09:36:56 -06:00
Dan Peebles
6018cf4a69 amazon-init.service: fix starting services at startup
We now make it happen later in the boot process so that multi-user
has already activated, so as to not run afoul of the logic in
switch-to-configuration.pl. It's not my favorite solution, but at
least it works. Also added a check to the VM test to catch the failure
so we don't break in future.

Fixes #23121
2017-02-27 16:51:36 +00:00
Tomasz Czyż
0b27c74eb2 pgjwt: init at 0.0.1 (#22644) 2017-02-26 11:14:32 +01:00
Jörg Thalheim
5b14e91717 Merge pull request #22822 from Mic92/iputils
iputils: 20151218 -> 20161105
2017-02-22 00:37:13 +01:00
Tomasz Czyż
ab22a08039 test all postgresql versions, test server restart (#1735) 2017-02-21 22:48:39 +00:00
aszlig
5af8b120a6
nixos/tests/taskserver: Add test for manual config
This subtest actually serves two purposes:

  1. Test manual PKI configuration
  2. Test changing of configuration files

In order to only test manual PKI configuration it would have been enough
to just add another server with a manual config.

But as the switch from automatic PKI config to manual config is probably
one of the most fundamental changes in configuration, so it serves
*very* well to also check whether changes in the NixOS configuration
actually have an impact in the real system.

So instead of adding another server, we now create a dummy "newServer"
machine, which is the new configuration for "server" and use
switch-to-configuration to switch "server" to the config of "newServer".

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2017-02-17 19:46:01 +01:00
Jörg Thalheim
fd78ff23f7
replace ping6 with ping
reason: after the upgrade of iputils from 20151218 to 20161105
functionality of ping6 and tracepath6 was merged into ping and tracepath.

Ping is now mostly a drop-in replacment for ping6, except that selecting a
specific interface is done by encoding it into the address (ex.: fe80::1%eth0)
rather then specifing it with the `-I` flag.
2017-02-17 16:04:49 +01:00
Profpatsch
9debdaf512 networking.bonds: add support for arbitrary driverOptions
Until now the four attributes available very selectively provided a small
subset, while copying upstream documentation.

We make driver options an arbitrary key-value set and point to kernel
documentation, which is always up-to-date. This way every option can be set.
The four already existing options are deprecated with a warning.
2017-02-16 21:24:40 +01:00
Ian-Woo Kim
b7a24e0a2b nixos-container: added test for port forwarding ( nixos/tests/containers-portforward.nix ) 2017-02-15 05:12:46 +01:00
Parnell Springmeyer
9e36a58649
Merging against upstream master 2017-02-13 17:16:28 -06:00
Graham Christensen
96d767de62
pam_oath: require OATH and pam_unix credentials to be valid 2017-02-12 18:27:11 -05:00
Graham Christensen
3cec7d10df
kdm: drop service 2017-02-11 13:55:09 -05:00
Graham Christensen
b12564cc1b
nixos: update default cases from KDM/KDE4 to SDDM/KDE5 2017-02-09 21:52:00 -05:00
Joachim Fasting
28b5cc7dca
grsecurity test: adapt to changes in tinycc outputs 2017-02-09 16:23:04 +01:00
aszlig
cd10e3c4ff
nixos/tests/chromium: Run tests as normal user
The tests have failed because Chromium has started up displaying the
following error message in a dialog window:

  Chromium can not be run as root.

  Please start Chromium as a normal user. If you need to run as root for
  development, rerun with the --no-sandbox flag.

So let's run as user "alice" and pass all commands using the small
helper function "ru" (to keep it short, it's for "Run as User").

Tested it by running the "stable" test on x86_64-linux.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Reported-by: @globin
2017-02-07 07:36:56 +01:00
Nikolay Amiantov
6812c7001c nfs tests: fix nfs server unit name 2017-02-05 12:41:21 +03:00
Damien Cassou
58dc8e3024
Remove myself from maintainers 2017-01-31 11:00:14 +01:00
Parnell Springmeyer
4aa0923009
Getting rid of the var indirection and using a bin path instead 2017-01-29 04:11:01 -06:00
Parnell Springmeyer
e92b8402b0
Addressing PR feedback 2017-01-28 20:48:03 -08:00
Parnell Springmeyer
a26a796d5c
Merging against master - updating smokingpig, rebase was going to be messy 2017-01-26 02:00:04 -08:00
Parnell Springmeyer
025555d7f1
More fixes and improvements 2017-01-26 00:05:40 -08:00
Robin Gloster
5de731c853
tests.bittorrent: use a file instead of a directory
nixUnstable.src is a directory, which made cp fail without -r
2017-01-26 02:44:05 +01:00
Robin Gloster
b79fa22b7a
tests.installer: rely on swap.target in tests
fixes #5258
2017-01-25 17:00:13 +01:00
Franz Pletz
2d9152d509
nixos/tests/nat: add test for conntrack helper autoloading 2017-01-25 01:14:05 +01:00
Franz Pletz
8322a12ef2
firewall: disable conntrack helper autoloading by default
This was disabled in the Linux kernel since 4.7 and poses a security risk
if not configured properly.

https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/?id=486dcf43da7815baa615822f3e46883ccca5400f
2017-01-25 01:14:04 +01:00
Charles Strahan
d298a961f1 Merge pull request #21416 from cstrahan/mesos-1.1.0
mesos: 1.0.1 -> 1.1.0
2017-01-21 19:05:18 -05:00
Nikolay Amiantov
70a6628848 Merge pull request #21882 from abbradar/dhcp6
DHCPv6 improvements
2017-01-15 19:53:33 +03:00
Nikolay Amiantov
86755d923b networking test: test IPv6 with RA and DHCPv6 2017-01-15 19:53:17 +03:00
Maarten Hoogendoorn
9f892de069 kubernetes vm test: make dig and netcat available
Dig could not be found in the test cases. Adding it as a global package
fixes this.
2017-01-15 13:28:16 +01:00
Antoine Eiche
165089f9d7 nixos/glance: add test
The test starts the glance service, creates a nixos image and ensures Glance
list it.

Note the test also starts the Keystone service since it is required
by Glance.
2016-12-31 09:36:57 +01:00
Charles Strahan
7ebcada020
mesos: 1.0.1 -> 1.1.0 2016-12-29 20:09:46 -05:00
Graham Christensen
bf659128a0
openssh: test that startWhenNeeded works 2016-12-29 17:04:52 -05:00
Eelco Dolstra
bb0ce819b3
nixos/tests/gnome3.nix: Speed up test
It turns out that "journalctl -f | grep -m 1 pattern" will block for
one more line after "pattern" appears, which can take a long time.
2016-12-29 16:23:31 +01:00
Jörg Thalheim
c23032a8b1 docker: update service units from upstream
All the new options in detail:

Enable docker in multi-user.target make container created with restart=always
to start. We still want socket activation as it decouples dependencies between
the existing of /var/run/docker.sock and the docker daemon. This means that
services can rely on the availability of this socket. Fixes #11478 #21303

  wantedBy = ["multi-user.target"];

This allows us to remove the postStart hack, as docker reports on its own when
it is ready.

  Type=notify

The following will set unset some limits because overhead in kernel's ressource
accounting was observed. Note that these limit only apply to containerd.
Containers will have their own limit set.

  LimitNPROC=infinity
  LimitCORE=infinity
  TasksMax=infinity

Upgrades may require schema migrations. This can delay the startup of dockerd.

  TimeoutStartSec=0

Allows docker to create its own cgroup subhierarchy to apply ressource limits on
containers.

  Delegate=true

When dockerd is killed, container should be not affected to allow
`live restore` to work.

  KillMode=process
2016-12-23 21:39:38 +01:00
Eelco Dolstra
2c03037450
Work around slowness in the KDE 5 test
The use of unionfs-fuse (57a0f14064)
slows down the KDE 5 test enough that it hits Hydra timeouts. (E.g. on
my laptop it went from ~5 min to ~30 min.) So disable it for the KDE
test.

http://hydra.nixos.org/build/45127422
(cherry picked from commit 3fcbcf2556)
2016-12-21 19:30:35 -05:00
Bjørn Forsman
3fb785b0ad nixos: unbreak prometheus test
target_groups was renamed to static_configs in d459916504
("prometheus service: rename values to match prometheus 1.0 naming.").
Catch up.
2016-12-20 23:26:51 +01:00
aszlig
02a9da65c9
nixos: Disable OCR for tests that do not use it
Found out during testing of the Tesseract upgrade the kde5 and sddm
tests don't actually use OCR, so let's disable support for it.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Cc: @ttuegel
2016-12-19 22:25:42 +01:00
Antoine Eiche
086e5d09a1 nixos/keystone: add test in release.nix 2016-12-16 20:53:32 +01:00
Antoine Eiche
a932f68d9c nixos/keystone: secrets can be read from files
A secret can be stored in a file. It is written at runtime in the
configuration file.
Note it is also possible to write them in the nix store for dev
purposes.
2016-12-16 20:53:32 +01:00
Antoine Eiche
415c9ff90b nixos/keystone: init at liberty version
This commit introduces a nixos module for the Openstack Keystone
service. It also provides a optional bootstrap step that creates some
basic initial resources (tenants, endpoints,...).

The provided test starts Keystone by enabling bootstrapping and checks
if user creation works well.

This commit is based on initial works made by domenkozar.
2016-12-16 20:53:32 +01:00
Joachim Fasting
64a64c6b14
grsecurity test: refactoring 2016-12-13 15:12:11 +01:00
montag451
ea5551b551 containers: fix broken /etc/hosts entries when localAddress contains a netmask 2016-12-12 09:20:28 +01:00
montag451
4889c271ca Add macvlan support for declarative containers 2016-12-12 07:34:28 +01:00
Franz Pletz
69bee1b361 Merge pull request #20770 from mguentner/more_ipfs
services: IPFS: add test and more config parameters
2016-12-04 01:46:09 +01:00
Graham Christensen
d5cb4d8734
ecryptfs test: use TTY output to stabilize test 2016-12-02 19:36:27 -05:00
Graham Christensen
b28d21fd50 Merge pull request #20808 from grahamc/fancy-test-tty
login test: Create and use direct reads of the TTY contents.
2016-11-30 11:27:49 -05:00
Graham Christensen
cb74fd75d7
login test: Create and use direct reads of the TTY contents. 2016-11-30 00:17:18 -05:00
Maximilian Güntner
f7c099bd8c
tests: added basic ipfs test
$getter can be used once ipfs supports private/local networks
and or internet gets routed to the VMs

Signed-off-by: Maximilian Güntner <code@klandest.in>
2016-11-28 15:33:58 +01:00
Vladimír Čunát
925b335607
Merge branch 'master' into staging 2016-11-26 11:27:09 +01:00
Jaka Hudoklin
3b500d37f5 Merge pull request #19023 from offlinehacker/kube-update
WIP: kubernetes update package and module
2016-11-24 23:10:01 +01:00
Frederik Rietdijk
25a9889f0e blivet test: use python2 2016-11-24 22:28:03 +01:00
Christian Kampka
35ecef2c6d containers module: Add tmpfs options (#20557)
Allows one or more directories to be mounted as a read-only file system.

This makes it convenient to run volatile containers that do not retain
application state.
2016-11-22 02:11:33 +01:00
Jaka Hudoklin
5bc7ae7adb kubernetes module: support for kubernetes 1.4 2016-11-17 02:46:31 +01:00
Joachim Fasting
999ac3056d
cjdns test: fix typo
Noticed by @vcunat
daf3ba426b (commitcomment-19820962)
2016-11-15 01:57:30 +01:00
Joachim Fasting
f059c7f754
Revert "cjdns test: exercise host builder logic"
This reverts commit daf3ba426b.

This is an alternative to 0ba3d429a7,
which disables the test outright.  Briefly, exercising builders which
rely on import-from-derivation can cause Hydra jobsets to time out.
2016-11-12 13:09:17 +01:00
aszlig
4e7eb75a79
nixos/tests/chromium: Fix popup detection
Sometimes it happens that the "Type to search or enter a URL to
navigate" popup doesn't show, but all we need to know at this time is
whether Chromium has finished starting up.

So checking for the "startup done" page is a better option here.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-11-09 09:41:10 +01:00
Joachim Schiele
47d81ed347 leaps: 0.5.1 + add a service + test 2016-11-06 10:34:42 +01:00
Joachim F
32715b8314 Merge pull request #17445 from joachifm/dnscrypt-proxy-update-list
dnscrypt-proxy service: auto-updated resolver list
2016-11-05 18:23:48 +01:00
Joachim Fasting
806e652e51
dnscrypt-proxy test: simplification 2016-11-05 17:45:02 +01:00
Joachim Fasting
daf3ba426b
cjdns test: exercise host builder logic 2016-11-04 13:45:04 +01:00
Tim Steinbach
04b22dd935 Merge pull request #19982 from sternenseemann/netcat
Make netcat-openbsd the default netcat
2016-11-02 19:44:29 -04:00
Bjørn Forsman
2f8ac21e1b nixos: remove test-config-examples.sh (obsolete)
This file has been non-functional for over two years, since
commit f002a27a80 ("Remove obsolete directory") removed
.../doc/config-examples/.
2016-11-02 22:46:19 +01:00
sternenseemann
e2372502d3 netcat: make netcat-openbsd the default netcat (#19411)
The motivation for this change is the following: As gnu-netcat,
e. g. does not support ipv6, it is not suitable as default netcat.

This commit also fixes all obvious build issues caused by this change.
2016-10-30 15:06:04 +01:00
Alexander Ried
bb8b48c794 mpich: remove unused test 2016-10-29 07:33:28 +02:00
Joachim Fasting
c86fe2224e virtualbox-{systemd-detect-virt,net-hostonlyif} test: fix dbus socket dir
The test complains[1][2] that

   Failed to start message bus: Failed to bind socket "/run/dbus/system_bus_socket": No such file or directory

In 639e5401ff, the dbus socket dir is set
to `/run/dbus`; in the test vm `/var/run/dbus` is used, but the standard
`/run -> /var/run` link is typically not created until stage 2 init, not
in the minimal init used here.  Thus, dbus fails to run within the test
environment .  Fix by changing `/var/run/dbus` to simply `/run/dbus`.

[1]: https://hydra.nixos.org/build/42534725
[2]: https://hydra.nixos.org/build/42523834
2016-10-26 03:00:54 +02:00
Graham Christensen
6c7a605714
hound: init module 2016-10-15 13:54:59 -04:00
Robin Gloster
dabcd7d4c8 dockerRegistry module: re-init with new underlying software 2016-10-12 14:05:09 +02:00
Joachim F
1997761725 Merge pull request #19367 from cransom/smokeping-fix
smokeping module: fix missing js, broken alerts
2016-10-10 16:06:39 +02:00
Jörg Thalheim
89e4d72fc8 Merge pull request #19128 from kampfschlaefer/fix_device_wait_in_containers
Fix device wait in containers
2016-10-10 11:40:31 +02:00
aszlig
aeec1bc5c8
tests/boot-stage1: Use runCommandCC for kcanary
Since 97bfc2fac9, runCommand doesn't
include a compiler anymore. So let's switch to the new runCommandCC,
which resembles the old state.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-10-09 14:15:19 +02:00
Casey Ransom
74558c88fb smokeping module: fix missing js, broken alerts
The initial commit accidentally left in some commented code and if you were
using alerts, they simply didn't work.

Smokeping also includes some JS code for the webui allowing you to zoom into
graphs and it was not passed into the homedir. Additionally, generate
static html pages for other webservers to serve the cache directory.

Add additional options to specify sendmail path or mailhost and verify that both
are not set.

Add one extra config hook that allows you to bypass all of the invidual config
stanzas and just hand it a string.
2016-10-08 20:52:45 -04:00
Arnold Krille
cc91f274e0 containers: Improve device dependency tracking
Now the tracking works with aggregated devices on aggregated devices.

So container with physical device where the device is put in a bond
which is the basis for a bridge is now handled correctly.
2016-10-08 22:28:49 +02:00
Arnold Krille
f0492bd53c containers: Do not wait for udev for network devices
Test that adding physical devices to containers works, find that network setup
then doesn't work because there is no udev in the container to tell systemd
that the device is present.
Fixed by not depending on the device in the container.

Activate the new container test for release

Bonds, bridges and other network devices need the underlying not as
dependency when used inside the container. Because the device is already
there.

But the address configuration needs the aggregated device itself.
2016-10-08 22:09:22 +02:00
Jörg Thalheim
888f6a1280 Merge pull request #19199 from wizeman/u/fix-help2man-hash
help2man: fix hash
2016-10-03 19:26:44 +02:00
Joachim F
0906a0f197 Merge pull request #18491 from groxxda/network-interfaces
Replace Network-interfaces.target
2016-10-02 16:34:37 +02:00
Tuomas Tynkkynen
19225bf5cc Merge remote-tracking branch 'upstream/master' into staging 2016-10-02 10:36:47 +03:00
Jörg Thalheim
0334b75e12
logstash: fix test
embedded elasticsearch was removed: https://www.elastic.co/blog/logstash-1-4-3-released
2016-10-01 23:18:24 +02:00
Jaka Hudoklin
98a8146428 Merge pull request #19016 from offlinehacker/pkgs/flannel/update/0.6.2
flannel: update, add nixos module, add tests
2016-10-01 17:22:34 +02:00
Jaka Hudoklin
feb9fc3aff flannel service: init 2016-10-01 17:08:48 +02:00
Eelco Dolstra
328c2f0081 Add a simple test for Samba 2016-09-30 21:24:18 +02:00
Eelco Dolstra
97bfc2fac9 runCommand: Use stdenvNoCC
This ensures that most "trivial" derivations used to build NixOS
configurations no longer depend on GCC. For commands that do invoke
gcc, there is runCommandCC.
2016-09-29 13:06:43 +02:00
Graham Christensen
4671806183
wordpress: 4.3.1 -> 4.6.1 + add a test 2016-09-26 19:36:07 -04:00
Domen Kožar
30e35d1218 Merge pull request #18622 from rvl/mongodb-test-default-i686
mongodb service: Add test case and fix default storage engine on i686
2016-09-21 14:19:45 +02:00
Domen Kožar
001d314e87 Merge pull request #18574 from ericsagnes/feat/mongodb
MongoDB service: switch configuration format to YAML
2016-09-21 14:19:17 +02:00
Thomas Tuegel
d7d74a1922
nixos/tests/kde5: fix test name 2016-09-20 14:53:36 -05:00
Eric Sagnes
9132088dab pump.io test: adapt mongodb extraConf to YAML 2016-09-18 09:30:04 +09:00
Rodney Lorrimar
795a6e7610 mongodb service: add test case 2016-09-17 10:47:36 +01:00
Eric Sagnes
2d2c311304 cadvisor test: fix (#18671)
* influxdb module: add postStart

* cadvisor module: increase TimeoutStartSec

Under high load, the cadvisor module can take longer than the default 90
seconds to start. This change should hopefully fix the test on Hydra.
2016-09-16 22:06:16 +02:00
Eric Sagnes
db387a6f0d cadvisor: fix test 2016-09-15 21:28:41 +09:00
aszlig
1781e95577
Merge pull request #18567 (VirtualBox 5.1.6)
This introduces VirtualBox version 5.1.6 along with a few refactored
stuff, notably:

  * Kernel modules and user space applications are now separate
    derivations.
  * If config.pulseaudio doesn't exist in nixpkgs config, the default is
    now to build with PulseAudio modules.
  * A new updater to keep VirtualBox up to date.

All subtests in nixos/tests/virtualbox.nix succeed on my machine and
VirtualBox was reported to be working by @DamienCassou (although with
unrelated audio problems for another fix/branch) and @calbrecht.
2016-09-14 02:20:16 +02:00
aszlig
f7563efa6e
nixos/tests/vbox: Add destroyVM for all subtests
One reason why it took me so long for debugging the test failure with
systemd-detect-virt was that simple-cli has succeeded while the former
has not.

This now makes sure we have consistency accross all the subtests and if
problems like the one in the previos commit ever show up again, we will
have just the headless test succeeding and it's more obvious where the
actual problem resides.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-09-14 02:12:16 +02:00
aszlig
80c2cc350c
nixos/tests/vbox: Disable audio for VBox guests
We don't have (simulated) sound hardware within the qemu VM, neither do
we have it available within VirtualBox that's running within the qemu
VMs.

With sound hardware the VirtualBox UI displays an error dialog, which in
turn causes the VM process to hang on unregister. This in turn has
caused the tests to fail because of the following error:

Cannot unregister the machine '...' while it is locked

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-09-13 23:17:47 +02:00
Reno Reckling
8ea8659f29 Remove tomcat vm test timing issues
(cherry picked from commit 090f1f0722)
Signed-off-by: Domen Kožar <domen@dev.si>
2016-09-13 22:46:46 +02:00
Jaka Hudoklin
7a9dd489d6 Merge pull request #18481 from offlinehacker/pkgs/docker/1.12.1
docker: 1.10.3 -> 1.12.1
2016-09-13 15:59:18 +02:00
aszlig
562c7f56f0
nixos/tests/vbox: Make shutdown less noisy
Using waitUntilSucceeds for testing whether the shutdown signalling
files have vanished is quite noisy because it prints two lines for every
try. This is now fixed with a while loop on the guest VM which does the
same check but with only one output for the command that's executed and
another one when the conditions are met.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-09-13 14:55:52 +02:00
Jaka Hudoklin
5d9c62541a docker module: updates
- logDriver option, use journald for logging by default
- keep storage driver intact by default, as docker has sane defaults
- do not choose storage driver in tests, docker will choose by itself
- use dockerd binary as "docker daemon" command is deprecated and will be
  removed
- add overlay2 to list of storage drivers
2016-09-13 12:51:13 +02:00
Alexander Ried
60a9edbbeb tests.networking: remove network-interfaces.target 2016-09-13 11:19:23 +02:00
Reno Reckling
6ff44c571b mumble: fix failing vm tests
modify tests to not fail if the event handlers are
registered too slowly or if the wrong window is in focus

(cherry picked from commit e087b0d12f)
Signed-off-by: Domen Kožar <domen@dev.si>
2016-09-13 09:45:08 +02:00
Franz Pletz
5a7e5537aa Merge pull request #18298 from teh/prometheus-service
Prometheus service
2016-09-11 23:18:36 +02:00
Domen Kožar
fed3501b07 Remove docker-registry as it's deprecated #18209 2016-09-09 18:50:42 +02:00
Thomas Tuegel
e5a79b0eae
nixos/tests/kde5: rename from sddm-kde5 and run by default
(cherry picked from commit 701f02a6ee)
2016-09-09 10:12:38 -05:00
Thomas Tuegel
0fdaae8be4
nixos/tests/sddm-kde5: don't run tests through krunner
(cherry picked from commit 1f510dc7cd)
2016-09-09 10:12:31 -05:00
Rodney Lorrimar
5537503dec nixos/tests/pump.io: Fix systemd unit config
Ref #18209

(cherry picked from commit 3fd603c02f)
2016-09-08 17:06:49 +01:00
Eric Sagnes
f39f829441 nixos: unbreak influxdb test (due to new API)
Data from the documentation example[1] was used.

[1] https://docs.influxdata.com/influxdb/v1.0/guides/writing_data/

[Bjørn: change commit message.]
2016-09-08 15:01:10 +02:00
aszlig
75efdc6502
nixos/tests/blivet: Fix btrfs-related tests
The loopback-based tests use a storage size of 102400 blocks (one block
is 1024 bytes), which doesn't seem to fit for btrfs volumes in recent
btrfs versions. I'm setting this to 409600 (400 MB) now so that it
should be enough for later versions in case they need even more space
for subvolumes.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-09-07 16:32:12 +02:00
aszlig
fb46df8a9a
nixos: Fix ordering of firewall.service
Follow-up to the following commits:

  abdc5961c3: Fix starting the firewall
  e090701e2d: Order before sysinit

Solely use sysinit.target here instead of multi-user.target because we
want to make sure that the iptables rules are applied *before* any
socket units are started.

The reason I've dropped the wantedBy on multi-user.target is that
sysinit.target is already a part of the dependency chain of
multi-user.target.

To make sure that this holds true, I've added a small test case to
ensure that during switch of the configuration the firewall.service is
considered as well.

Tested using the firewall NixOS test.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Cc: @edolstra
2016-09-07 15:11:24 +02:00
Benjamin Staffin
58869cf310 prometheus service: add
This is based on @benleys work: https://github.com/NixOS/nixpkgs/pull/8216
I updated changed the user and group ids.
2016-09-04 20:03:32 +01:00
Jaka Hudoklin
c083ab99b2 Merge pull request #17969 from offlinehacker/pkgs/etcd/update-3.0.6
Update etcd, improve nixos module, fix nixos tests
2016-09-04 16:31:50 +02:00
Jörg Thalheim
94dd66882f ferm: fix race condition in integration test (#18288)
curl sent the request faster then nginx bound the port in some cases
2016-09-04 14:34:06 +02:00
Joachim F
78b4b632ae Merge pull request #18085 from Mic92/ferm
ferm: add integration test
2016-09-03 17:27:38 +02:00
Joachim F
3db5311be9 Merge pull request #18207 from tavyc/quagga-module
quagga service: init
2016-09-03 16:23:23 +02:00
Graham Christensen
ff5fd1ec40 etcd-cluster: split up openssl commands 2016-09-03 13:59:28 +02:00
Vladimír Čunát
02217bf697 Merge #17838: postgresql: Fix use with extensions 2016-09-02 20:09:40 +02:00
Octavian Cerna
eb14130934 quagga test: Add test for the quagga service. 2016-09-02 14:00:32 +03:00
Lancelot SIX
5b8072fff6
postgresql: Fix use with extensions
Fixes #15512 and #16032

With the multi output, postgresql cannot find at runtime what is its
basedir when looking for libdir and pkglibdir. This commit fixes that.
2016-09-02 11:51:21 +02:00
Данило Глинський (Danylo Hlynskyi)
78cd9f8ebc virtualbox: add headless build (without Qt dependency) (#18026) 2016-09-01 20:54:58 +02:00
Jörg Thalheim
2ed6529444
ferm: add integration test 2016-08-29 15:34:30 +02:00
Jaka Hudoklin
0630233afa etcd module: add test for simple one node etcd service 2016-08-25 14:42:22 +02:00
Jaka Hudoklin
8256c07fc0 etcd module: add support for ssl, better defaults, fix tests 2016-08-24 20:12:24 +02:00
obadz
0e8d2725dc Merge branch 'master' into staging 2016-08-23 18:50:06 +01:00
Eelco Dolstra
3fe93d2f75 Fix virtualbox test evaluation 2016-08-23 13:05:14 +02:00
Tuomas Tynkkynen
74a3a2cd7e treewide: Use makeBinPath 2016-08-23 01:18:10 +03:00
Robin Gloster
33e1c78ae3 Merge remote-tracking branch 'upstream/master' into hardened-stdenv 2016-08-16 07:54:01 +00:00
obadz
1759825b34 nixos/tests/ecryptfs: placate some commands causing many builds failure
These commands shouldn't have to be here in the first place as ecryptfs
homes should be automatically unmounted during logoff.
2016-08-16 02:47:08 +01:00
Robin Gloster
bea8972d96 nixos.tests.boot-stage1: disable pic for kernel module 2016-08-13 09:49:24 +00:00
Graham Christensen
5d2980aa8e
gocd-agent / gocd-server: Reduce test memory requirements so Hydra builds 2016-08-10 16:21:35 -04:00
Graham Christensen
d969f3fa51
gocd-agent: 16.7.0 startup fixes + test improvements
- Agent now takes a full URL to the Go.CD server
 - Instruct the agent to attempt restart every 30s upon failure
 - Test's Accept header did not match the server's expectation
 - Replace the tests' complex Awk matches with calls to `jq`
2016-08-10 15:47:29 -04:00
Shawn Warren
8750b4892e bump gocd-agent version to 16.6.0-3590 (#17311)
Update gocd-agent package version to 16.6.0-3590 including new sha.  Modify heapSize
and maxMemory mkOption to accurately reflect their intended purpose of configuring
initial java heap sizes.
2016-08-10 17:10:13 +02:00
Frederik Rietdijk
8955dc5e7e Merge pull request #17464 from cransom/cassandra
Cassandra
2016-08-10 11:42:57 +02:00
obadz
74b3ad148d nixos/tests/installer.nix: add libxml2 & libxslt to prevent download attempts 2016-08-09 17:01:42 +01:00
Casey Ransom
9ecc587e3b cassandra service: init
The module will configure a Cassandra server with common options being
tweakable. Included is also a test which will spin up 3 nodes and
verify that the cluster can be formed, broken, and repaired.
2016-08-02 20:58:35 -04:00
Arnold Krille
07de11f165 containers: add myself to the maintainers of the tests
Seems like the right thing to do.
2016-07-28 23:06:41 +02:00
Arnold Krille
9045a8e24c declarative containers: additional veths
With these changes, a container can have more then one veth-pair. This allows for example to have LAN and DMZ as bridges on the host and add dedicated containers for proxies, ipv4-firewall and ipv6-firewall. Or to have a bridge for normal WAN, one bridge for administration and one bridge for customer-internal communication. So that web-server containers can be reached from outside per http, from the management via ssh and can talk to their database via the customer network.

The scripts to set up the containers are now rendered several times instead of just one template. The scripts now contain per-container code to configure the extra veth interfaces. The default template without support for extra-veths is still rendered for the imperative containers.

Also a test is there to see if extra veths can be placed into host-bridges or can be reached via routing.
2016-07-28 23:06:41 +02:00
Luca Bruno
5c738ec37e gnome3: drop 3.18 2016-07-25 22:49:12 +02:00
Joachim Fasting
88138d43fa
grsecurity test: add note explaining what the tcc -run test accomplishes 2016-07-24 12:54:07 +02:00
Joachim Fasting
8c8d6b4053
grsecurity test: verify that the grsec device node is created 2016-07-24 12:54:07 +02:00
ben smith
c38e6a2a60 mysql: fix replication tests (#17174)
Eliminate race condition in replication test
Remove replication configuration from standalone test
Improve mysql command syntax consistency
2016-07-23 00:37:05 +02:00
Shawn Warren
9886c80daa Add gocd agent and server service packages (#16273)
GoCD is an open source continuous delivery server specializing in advanced workflow
modeling and visualization.  Update maintainers list to include swarren83.  Update
module list to include gocd agent and server module.  Update packages list to include
gocd agent and server package.  Update version, revision and checksum for GoCD
release 16.5.0.
2016-07-23 00:29:18 +02:00
cransom
4a9b640f37 smokeping: init at 2.6.11 (#17090)
Includes a module for service setup and a test
to verify functionality of both service and pkg.
2016-07-21 01:07:59 +02:00
Nikolay Amiantov
9cc70b419c nixos/tests: add hibernation test 2016-07-19 05:20:02 +03:00
obadz
08fe395074 nixos/tests/installer.nix: add curl on host machine
add curl so that rather than seeing the test attempt to download
curl's tarball, we see what it's trying to download.
2016-07-17 21:17:55 +01:00
Nikolay Amiantov
f4ea97ae90 Revert "nixos/tests/installer: Fix matching LUKS prompt"
This reverts commit ec072cbc4c.

See also 193ab8be67
2016-07-17 22:44:54 +03:00
aszlig
ec072cbc4c
nixos/tests/installer: Fix matching LUKS prompt
The LUKS passphrase prompt has changed from "Enter passphrase" to "Enter
LUKS Passphrase" in c69c76ca7e, so the OCR
detection of the test fails indefinitely.

Unfortunately, this doesn't fix the test because we have a real problem
here:

Enter LUKS Passphrase:
killall: cryptsetup: no process killed
Enter LUKS Passphrase:

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Cc: @abbradar
2016-07-17 11:20:25 +02:00
obadz
d781bf94c1 ecryptfs: test bug from #16766 2016-07-13 02:00:22 +02:00
obadz
ab6fc29719 ecryptfs: add nixos/tests/ecryptfs.nix 2016-07-13 01:48:41 +02:00
Luca Bruno
5a245c24b0 gnome3: make 3.20 the default 2016-07-10 16:17:37 +02:00
Damien Cassou
fff2d6f395 Add test for emacs module 2016-07-01 11:37:57 +02:00
Joachim Fasting
09cf92ccee
nixos: flesh out the grsecurity test suite
I've failed to figure out what why `paxtest blackhat` hangs the vm, and
have resigned to running individual `paxtest` programs.  This provides
limited coverage, but at least verifies that some important features are
in fact working.

Ideas for future work includes a subtest for basic desktop
functionality.
2016-06-14 03:38:18 +02:00
Damien Cassou
da62589d8e gnome3_20: Add GNOME 3.20 package set 2016-06-06 20:33:58 +02:00
Joel Moberg
20826c2a5d nixos kde5: improve test
IceWM is not part of KDE 5 and is now no longer part of the test. KDE 5
applications: Dolphin, System Monitor, and System Settings are started
in this test.
2016-06-01 17:09:51 +02:00
Eelco Dolstra
9f0e137338 Rename boot.loader.gummiboot.enable -> boot.loader.systemd-boot.enable 2016-06-01 12:55:52 +02:00
Eelco Dolstra
f222689aba Use systemd-boot instead of gummiboot
Gummiboot is part of systemd now so we may as well use it.
2016-05-31 17:02:47 +02:00
aszlig
3b8a2a793c
nixos/tests/vbox: Fix invocation of dbus
VBoxService needs dbus in order to work properly, which failed to start
up so far, because it was searching in /run/current-system/sw for its
configuration files.

We now no longer run with the --system flag but specify the
configuration file directly instead.

This fixes at least the "simple-gui" test and probably the others as
well, which I haven't tested yet.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-26 16:48:32 +02:00
aszlig
3fd3911105
nixos/tests/vbox: Replace waitForWindow with xprop
We can't use waitForWindow here because it runs xwininfo as user root,
who in turn is not authorized to connect to the X server running as
alice.

So instead, we use xprop from user alice which should fix waiting for
the VirtualBox manager window.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-26 16:48:32 +02:00
aszlig
ecd3cbb9e7
nixos/tests/vbox: Start X server with user "alice"
The VirtualBox tests so far ran the X server as root instead of user
"alice" and it did work, because we had access control turned off by
default.

Fortunately, it was changed in 1541fa351b.

As a side effect, it caused all the VirtualBox tests to fail because
they now can't connect to the X server, which is a good thing because
it's a bug of the VirtualBox tests.

So to fix it, let's just start the X server as user alice.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-26 15:05:23 +02:00
obadz
e78a99c35b nixos/tests/installer.nix: nixos-generate-config detects LUKS since a7baec7
Fixes nix-build '<nixos/release.nix>' -A tests.installer.luksroot.x86_64-linux
2016-05-26 04:02:36 +01:00
Eelco Dolstra
845c9b50bf boot.initrd.luks.devices: Change into an attribute set
This allows setting options for the same LUKS device in different
modules. For example, the auto-generated hardware-configuration.nix
can contain

  boot.initrd.luks.devices.crypted.device = "/dev/disk/...";

while configuration.nix can add

  boot.initrd.luks.devices.crypted.allowDiscards = true;

Also updated the examples/docs to use /disk/disk/by-uuid instead of
/dev/sda, since we shouldn't promote the use of the latter.
2016-05-25 18:04:21 +02:00
Eelco Dolstra
fe875b4100 nixos/tests/boot.nix: Remove empty module 2016-05-25 11:39:17 +02:00
Eelco Dolstra
3e7b510281 nixos.tests.swraid: Drop mdadm -W
This command is racy because it will return a non-zero exit code if
the array is already clean. This caused numerous random failures. It
should be unnecessary anyway. (Maybe in the past we needed this
because of #15226.)

http://hydra.nixos.org/job/nixos/release-16.03/nixos.tests.installer.swraid.i686-linux
2016-05-24 17:20:22 +02:00
Domen Kožar
b49bf121b8 rename iElectric to domenkozar to match GitHub 2016-05-17 13:00:47 +01:00
aszlig
64ca91cac9
nixos/tests/boot-stage1: Add myself to maintainers
As @edolstra pointed out that the kernel module might be painful to
maintain. I strongly disagree because it's only a small module and it's
good to have such a canary in the tests no matter how the bootup process
looks like, so I'm going the masochistic route and try to maintain it.

If it *really* becomes too much maintenance burden, we can still drop or
disable kcanary.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-06 21:32:21 +02:00
aszlig
4f796c28d5
nixos/tests: Add a test for boot stage 1
We already have a small regression test for #15226 within the swraid
installer test. Unfortunately, we only check there whether the md
kthread got signalled but not whether other rampaging processes are
still alive that *should* have been killed.

So in order to do this we provide multiple canary processes which are
checked after the system has booted up:

 * canary1: It's a simple forking daemon which just sleeps until it's
            going to be killed. Of course we expect this process to not
            be alive anymore after boot up.
 * canary2: Similar to canary1, but tries to mimick a kthread to make
            sure that it's going to be properly killed at the end of
            stage 1.
 * canary3: Like canary2, but this time using a @ in front of its
            command name to actually prevent it from being killed.
 * kcanary: This one is a real kthread and it runs until killed, which
            shouldn't be the case.

Tested with and without 67223ee and everything works as expected, at
least on my machine.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-06 16:56:43 +02:00
aszlig
dc6d003011
nixos/tests/installer/swraid: Check for safemode
This is a regression test for #15226, so that the test will fail once we
accidentally kill one or more of the md kthreads (aka: if safe mode is
enabled).

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-06 16:51:38 +02:00
zimbatm
f076f36f8f Merge pull request #14957 from dezgeg/gummiboot-test
NixOS installer tests: Add a test using Gummiboot
2016-05-05 21:14:30 +01:00
aszlig
acf7bc898a
nixos/tests/containers: Remove unused module arg
Just removing the system argument because it doesn't exist (it's
actually config.nixpkgs.system, which we're already using). We won't get
an error anyway if we're not actually using it, so this is just an
aesthetics fix.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-04 20:51:01 +02:00
aszlig
9fa30d3bad
nixos/tests/containers-imperative: Fix test
Make sure that we always have everything available within the store of
the VM, so let's evaluate/build the test container fully on the host
system and propagate all dependencies to the VM.

This way, even if there are additional default dependencies that come
with containers in the future we should be on the safe side as these
dependencies should now be included for the test as well.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Cc: @kampfschlaefer, @edolstra
2016-05-04 20:18:27 +02:00
aszlig
f35e9386bd
nixos/tests/chromium: Re-add map for all channels
This partially reverts f2d24b9840.

Instead of disabling the channels via removing the channel mapping from
the tests themselves, let's just explicitly reference the stable test in
release.nix. That way it's still possible to run the beta and dev tests
via something like "nix-build nixos/tests/chromium.nix -A beta" and
achieve the same effect of not building beta and dev versions on Hydra.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-04 18:45:44 +02:00
Eelco Dolstra
f2d24b9840 chromium: Disable Hydra builds of -dev and -beta
It's not the job of Nixpkgs to distribute beta versions of upstream
packages. More importantly, building these delays channel updates by
several hours, which is bad for our security fix turnaround time.
2016-05-04 18:16:27 +02:00
aszlig
e7d3166656
nixos/tests/netboot: Fix evaluation error
Regression introduced by dfe608c8a2.

The commit turns the two arguments into one attrset argument so we need
to adapt that to use the new calling convention.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-05-03 22:05:11 +02:00
Nahum Shalman
83c0aca062 installer: simple PXE bootable NixOS installer
The Nix store squashfs is stored inside the initrd instead of separately

(cherry picked from commit 976fd407796877b538c470d3a5253ad3e1f7bc68)
Signed-off-by: Domen Kožar <domen@dev.si>
2016-04-29 10:42:39 +01:00
Tuomas Tynkkynen
1feed61164 NixOS installer tests: Add a test using Gummiboot
Issue #14956
2016-04-24 22:05:48 +03:00
Franz Pletz
8cca66f774 Merge pull request #14018 from kampfschlaefer/feature/hostbridge_and_ipv6_for_containers
containers: hostbridge and IPv6
2016-04-24 20:33:46 +02:00
Vladimír Čunát
a1b39b9990 cups tests: finally fix them
Fixes #14748.
2016-04-23 16:17:22 +02:00
Joachim Fasting
55a82158e2
Revert "nixos.tests.printing: fix"
This reverts commit 49894ac857.

Reverting in deference to https://github.com/NixOS/nixpkgs/issues/14782
2016-04-18 13:40:35 +02:00
Joachim Fasting
49894ac857
nixos.tests.printing: fix
Two fixes:

Not really sure why removing `--fail` from the curl calls is necessary,
but with that option, curl erronously reports 404 (which it shouldn't
per my interactive vm testing).

Fix paths to example files used for the printing test

Toghether, these changes allow the test to run to completion on my machine.
2016-04-18 02:21:12 +02:00
aszlig
9ed9e268a2
Merge pull request #14476 (taskserver)
This adds a Taskserver module along with documentation and a small
helper tool which eases managing a custom CA along with Taskserver
organisations, users and groups.

Taskserver is the server component of Taskwarrior, a TODO list
application for the command line.

The work has been started by @matthiasbeyer back in mid 2015 and I have
continued to work on it recently, so this merge contains commits from
both of us.

Thanks particularly to @nbp and @matthiasbeyer for reviewing and
suggesting improvements.

I've tested this with the new test (nixos/tests/taskserver.nix) this
branch adds and it fails because of the changes introduced by the
closure-size branch, so we need to do additional work on base of this.
2016-04-15 00:21:49 +02:00
Vladimír Čunát
39ebb01d6e Merge branch 'staging', containing closure-size #7701 2016-04-13 09:25:28 +02:00
Eelco Dolstra
a42698d2a4 Add a regression test for #14623 2016-04-12 19:13:52 +02:00
Eelco Dolstra
9153d8ed64 Fix X11 tests broken by the removal of -ac
Probably missed a few. Also adding xauth to the system path (it was
already in the closure).
2016-04-12 19:13:47 +02:00
Tuomas Tynkkynen
87b49397bf installer tests: Use different package for testing nix-env -iA
Coreutils is multi-output and the `info` output doesn't seem to be
included on the install disk, failing like this (because now nix-env
wants to build coreutils):

````
machine# these derivations will be built:
machine#   /nix/store/0jk4wzg11sa6cqyw8g7w5lb35axji969-bison-3.0.4.tar.gz.drv
...
machine#   /nix/store/ybjgqwxx63l8cj1s7b8axx09wz06kxbv-coreutils-8.25.drv
machine# building path(s) ‘/nix/store/4xvdi5740vq8vlsi48lik3saz0v5jsx0-coreutils-8.25.tar.xz’
machine# downloading ‘http://ftpmirror.gnu.org/coreutils/coreutils-8.25.tar.xz’...
machine# error: unable to download ‘http://ftpmirror.gnu.org/coreutils/coreutils-8.25.tar.xz’: Couldn't resolve host name (6)
machine# builder for ‘/nix/store/5j3bc5sjr6271fnjh9gk9hrid8kgbpx3-coreutils-8.25.tar.xz.drv’ failed with exit code 1
machine# cannot build derivation ‘/nix/store/ybjgqwxx63l8cj1s7b8axx09wz06kxbv-coreutils-8.25.drv’: 1 dependencies couldn't be built
machine# error: build of ‘/nix/store/ybjgqwxx63l8cj1s7b8axx09wz06kxbv-coreutils-8.25.drv’ failed
````
2016-04-12 17:29:15 +03:00
aszlig
e2383b84f8
nixos/taskserver/helper: Improve CLI subcommands
Try to match the subcommands to act more like the subcommands from the
taskd binary and also add a subcommand to list groups.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-12 05:38:37 +02:00
aszlig
ce0954020c
nixos/taskserver: Set allowedTCPPorts accordingly
As suggested by @matthiasbeyer:

"We might add a short note that this port has to be opened in the
firewall, or is this done by the service automatically?"

This commit now adds the listenPort to
networking.firewall.allowedTCPPorts as soon as the listenHost is not
"localhost".

In addition to that, this is now also documented in the listenHost
option declaration and I have removed disabling of the firewall from the
VM test.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-12 05:16:15 +02:00
aszlig
a41b109bc1
nixos/taskserver: Don't change imperative users
Whenever the nixos-taskserver tool was invoked manually for creating an
organisation/group/user we now add an empty file called .imperative to
the data directory.

During the preStart of the Taskserver service, we use process-json which
in turn now checks whether those .imperative files exist and if so, it
doesn't do anything with it.

This should now ensure that whenever there is a manually created user,
it doesn't get killed off by the declarative configuration in case it
shouldn't exist within that configuration.

In addition, we also add a small subtest to check whether this is
happening or not and fail if the imperatively created user got deleted
by process-json.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-12 03:42:13 +02:00
aszlig
cfb6ce2abe
nixos/tests/taskserver: Make tests less noisy
We were putting the whole output of "nixos-taskserver export-user" from
the server to the respective client and on every such operation the
whole output was shown again in the test log.

Now we're *only* showing these details whenever a user import fails on
the client.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-12 01:49:47 +02:00
aszlig
7889fcfa41
nixos/taskserver/helper: Implement deletion
Now we finally can delete organisations, groups and users along with
certificate revocation. The new subtests now make sure that the client
certificate is also revoked (both when removing the whole organisation
and just a single user).

If we use the imperative way to add and delete users, we have to restart
the Taskserver in order for the CRL to be effective.

However, by using the declarative configuration we now get this for
free, because removing a user will also restart the service and thus its
client certificate will end up in the CRL.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-12 01:41:41 +02:00
aszlig
3affead91b
nixos/taskserver: Move .pki.fqdn to .fqdn
It's not necessarily related to the PKI options, because this is also
used for setting the server address on the Taskwarrior client.

So if someone doesn't have his/her own certificates from another CA, all
options that need to be adjusted are in .pki. And if someone doesn't
want to bother with getting certificates from another CA, (s)he just
doesn't set anything in .pki.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-11 12:42:20 +02:00
aszlig
6de94e7d24
nixos/taskserver: Rename .server options to .pki
After moving out the PKI-unrelated options, let's name this a bit more
appropriate, so we can finally get rid of the taskserver.server thing.

This also moves taskserver.caCert to taskserver.pki.caCert, because that
clearly belongs to the PKI options.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-11 12:38:16 +02:00
aszlig
d6bd457d1f
nixos/taskserver: Rename server.{host,port}
Having an option called services.taskserver.server.host is quite
confusing because we already have "server" in the service name, so let's
first get rid of the listening options before we rename the rest of the
options in that .server attribute.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-11 12:26:34 +02:00
aszlig
636e0e552d
nixos/tests/taskserver: Test imperative users
As the nixos-taskserver command can also be used to imperatively manage
users, we need to test this as well.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-11 12:03:16 +02:00
Joachim Fasting
cef2814a4f nixos: add optional process information hiding
This module adds an option `security.hideProcessInformation` that, when
enabled, restricts access to process information such as command-line
arguments to the process owner.  The module adds a static group "proc"
whose members are exempt from process information hiding.

Ideally, this feature would be implemented by simply adding the
appropriate mount options to `fileSystems."/proc".fsOptions`, but this
was found to not work in vmtests. To ensure that process information
hiding is enforced, we use a systemd service unit that remounts `/proc`
after `systemd-remount-fs.service` has completed.

To verify the correctness of the feature, simple tests were added to
nixos/tests/misc: the test ensures that unprivileged users cannot see
process information owned by another user, while members of "proc" CAN.

Thanks to @abbradar for feedback and suggestions.
2016-04-10 12:27:06 +02:00
Vladimír Čunát
d1df28f8e5 Merge 'staging' into closure-size
This is mainly to get the update of bootstrap tools.
Otherwise there were mysterious segfaults:
https://github.com/NixOS/nixpkgs/pull/7701#issuecomment-203389817
2016-04-07 14:40:51 +02:00
aszlig
2d89617052
nixos/taskserver: Rename nixos-taskdctl
Using nixos-taskserver is more verbose but less cryptic and I think it
fits the purpose better because it can't be confused to be a wrapper
around the taskdctl command from the upstream project as
nixos-taskserver shares no commonalities with it.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-05 18:53:31 +02:00
aszlig
61b8d9ebe0
nixos/tests: Add a test for the Taskserver service
A small test which checks whether tasks can be synced using the
Taskserver.

It doesn't test group functionality because I suspect that they're not
yet implemented upstream. I haven't done an in-depth check on that but I
couldn't find a method of linking groups to users yet so I guess this
will get in with one of the text releases of Taskwarrior/Taskserver.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-04-05 18:53:31 +02:00
Arnold Krille
2d6a2b4131 containers tests: Distinguish declarative and imperative containers 2016-04-02 17:07:41 +02:00
Arnold Krille
3b31c52d4b containers: Add more tests for ipv6 and hostbridge
A testcase each for
- declarative ipv6-only container
  Seems odd to define the container IPs with their prefix length attached.
  There should be a better way…
- declarative bridged container

Also fix the ping test by waiting for the container to start

When the ping was executed, the container might not have finished starting. Or
the host-side of the container wasn't finished with config. Waiting for
2 seconds in between fixes this.
2016-04-02 17:07:41 +02:00
Vladimír Čunát
ab15a62c68 Merge branch 'master' into closure-size
Beware that stdenv doesn't build. It seems something more will be needed
than just resolution of merge conflicts.
2016-04-01 10:06:01 +02:00
aszlig
a3ac630092
nixos/tests: Add a test for keyboard layouts
I had the basic version of this laying around for some while but didn't
continue on it. Originally it was for testing support for the Neo layout
introduced back then (8cd6d53).

We only test the first three Neo layers, because the last three layers
are largely comprised of special characters and in addition to that the
support for the VT keymap seems to be limited compared to the Xorg
keymap.

Yesterday @NicolasPetton on IRC had troubles with the Colemak layout
(IRC logs: http://nixos.org/irc/logs/log.20160330, starting at 16:08)
and I found that test again, so I went for improving and adding to
<nixpkgs>.

While the original problem seemed to be related to GDM, we can still add
another subtest that checks whether GDM correctly applies the keyboard
layout. However I don't have a clue how to properly configure the
keyboard layout on GDM, at least not within the NixOS configuration.

The main goal of this test is not to test a complete set of all key
mappings but to check whether the keymap is loaded and working at all.

It also serves as an example for NixOS keyboard configurations.

The list of keyboard layouts is by no means complete, so everybody is
free to add their own to the test or improve the existing ones.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-03-31 09:49:08 +02:00
Eelco Dolstra
1783e33b06 Fix the boot-ec2-config test 2016-03-30 22:22:40 +02:00
Eelco Dolstra
0d3738cdcc Fix the EC2 test
We now generate a qcow2 image to prevent hitting Hydra's output size
limit. Also updated /root/user-data -> /etc/ec2-metadata/user-data.

http://hydra.nixos.org/build/33843133
2016-03-30 21:50:23 +02:00
Graham Christensen
37617a2c45 nixos.tests.installer.swraid: mdadm verbosity
These two steps seem to fail intermittently with exit code 1. It isn't clear to me why, or what the issue is. Adding the `--verbose` option, hoping to capture some debugging information which might aid stabilization. Also: I was unable to replicate the failure locally.
2016-03-28 14:00:00 -05:00
Joachim Fasting
ea443d719c nixos/tests: implement a trivial test for sudo
This is an alternative to NixOS/nixpkgs#6721, with
improvements suggested by @edolstra
2016-03-25 06:33:11 +01:00
Joachim Fasting
2438c61255 dnscrypt-proxy vmtest: more specific waitForUnit
The test sometimes times out waiting for multi-user.target; this
should be more robust.
2016-03-24 17:14:22 +01:00
Domen Kožar
ba78130c21 remove elrangR15 and riak 1.3.0 as they're outdated
(cherry picked from commit 4452a68425)
Signed-off-by: Domen Kožar <domen@dev.si>
2016-03-22 21:40:07 +00:00
aszlig
e047d79279
nixos/tests/chromium: Propagate "system" to pkgs
Assigning the channelMap by the function attrset argument at the
top-level of the test expression file may reference a different
architecture than we need for the tests.

So if we get the pkgs attribute by auto-calling, this will lead to test
failure because we have a different architecture for the test than for
the browser.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-03-21 03:50:38 +01:00
aszlig
3bd71b135b
nixos/tests/chromium: Allow overriding channel map
This has been the case before e45c211, but it turns out that it's very
useful to override the channel packages so we can run tests with
different Chromium build options.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-03-20 22:20:39 +01:00
Joachim Fasting
ece457c62f nixos/tests: fix docker test
The docker service is socket activated by default; thus,
`waitForUnit("docker.service")` before any docker command causes the
unit test to time out.

Instead, do `waitForUnit("sockets.target")` to ensure that sockets are
setup before running docker commands.
2016-03-19 03:18:17 +01:00
Peter Simons
c523aeffde nixos/tests/firewall.nix: ping now succeeds in the firewall's default configuration 2016-03-18 11:44:07 +01:00
Joachim Fasting
19492185fa nixos/tests: implement dnscrypt-proxy test
This test verifies that the daemon actually activates upon a
user-initiated ping, when using the recommended configuration.
2016-03-11 11:35:09 +01:00
Vladimír Čunát
09af15654f Merge master into closure-size
The kde-5 stuff still didn't merge well.
I hand-fixed what I saw, but there may be more problems.
2016-03-08 09:58:19 +01:00
joachifm
4fa37759be Merge pull request #13548 from joelmo/nixos-unstable
avahi: fix test
2016-03-02 20:55:42 +00:00
Domen Kožar
ba05826707 Attempt to fix transient grub1 test kernel panics
Example: http://hydra.nixos.org/build/32469819/nixlog/26/raw
2016-03-02 17:31:57 +00:00
aszlig
1f89aa6c7f
nixos/tests: Remove tests.boot.boot* prefixes
As @bobvanderlinden suggests in #13585:

"Looks like that cleans things up quite a bit! Just one aesthetics note,
the boot tests could now be renamed from boot.bootBiosCdrom to
boot.biosCdrom in nixos/tests/boot.nix:L33.

That makes them more consistent with the other tests."

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-03-01 19:02:36 +01:00
aszlig
e45c211b50
nixos/tests/chromium: Split up into subtests
This makes it easier to test just a specific channel rather than to
force testing all builds down the users/testers throat. Especially this
makes it easier to test NixOS channel upgrades only against the Chromium
stable channel instead of just removing the beta/dev channels from the
tests entirely (as done in 69ec09f38a).

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-03-01 01:04:51 +01:00
aszlig
2f2536b935
nixos/tests/networking: Expose subtests via attrs
So far the networking test expression only generated a single test
depending on the passed "test" attribute. This makes it difficult to
autodiscover the subtests with our shiny new callSubTests function.

This change essentially doesn't change the behaviour of the subtests but
rather exposes them as an attribute set instead of relying on a
particular input argument.

The useNetworkd argument still exists however.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Cc: @wkennington
2016-03-01 01:04:42 +01:00
aszlig
5bab623fb9
nixos/tests/virtualbox: Split up subtests
Now subtests are separate derivations, because the individual tests do
not depend on state from previous test runs.

This has the advantage that it's easier to run individiual tests and
it's also easier to pinpoint individual tests that randomly fail.

I ran all of these tests locally and they still succeed.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-02-29 20:15:31 +01:00
Joel Moberg
75e96d2c30 avahi: fix test
Reflects module changes made by cdd7310a50
2016-02-28 16:18:39 +01:00
Eelco Dolstra
d4636fa254 Revert "Add a way to pin a NixOS version within the module system."
This reverts commit a5992ad61b. Motivation:

a5992ad61b (commitcomment-14986820)
2016-02-27 20:48:12 +01:00
Nikolay Amiantov
8b124b7521 nixos.tests.printing: fix for new CUPS version
It looks like now queue is not immediately cleared from cancelled jobs.
Instead, files like "c00001" are left alongside "d00001-001", and
cleanup happens at some later point of time. Also, all new jobs are
assigned consecutive numbers now (00002, 00003 etc.). So when
original d00001 file is finally cleaned, it breaks the test. Fixed
by checking for any "d*" file inside the queue and cleaning it by
ourselves to ensure that each job works correctly.
2016-02-22 12:42:06 +03:00
Vladimír Čunát
d039c87984 Merge branch 'master' into closure-size 2016-02-14 08:33:51 +01:00
Eelco Dolstra
abdbdbebf6 nixos/tests/simple.nix: Include minimal.nix
This reduces the amount of rebuilds (particularly some X11 stuff)
after changing some dependencies like systemd.
2016-02-12 14:35:41 +01:00
Aneesh Agrawal
3c5fca9618 filesystems: use list of strings for fs options
Allow usage of list of strings instead of a comma-separated string
for filesystem options. Deprecate the comma-separated string style
with a warning message; convert this to a hard error after 16.09.
15.09 was just released, so this provides a deprecation period during
the 16.03 release.

closes #10518

Signed-off-by: Robin Gloster <mail@glob.in>
2016-02-06 19:48:30 +00:00
Robin Gloster
f7aa921773 Merge pull request #12560 from tvestelind/haka
Haka: new package
2016-02-06 20:32:39 +01:00
Vladimír Čunát
ae74c356d9 Merge recent 'staging' into closure-size
Let's get rid of those merge conflicts.
2016-02-03 16:57:19 +01:00
Eelco Dolstra
69ec09f38a Don't make chromium-beta/dev release blockers
Generally we shouldn't ship pre-release versions anyway, and we
certainly don't want them to be release blockers. Also, chromium
builds are just too slow to have them blocking the channel (see
https://github.com/NixOS/nixpkgs/issues/12794).
2016-02-03 11:49:50 +01:00
Eelco Dolstra
cc925d0506 boot.initrd.network: Support DHCP
This allows us to use it for EC2 instances.
2016-02-02 19:59:27 +01:00
Dan Peebles
dd18447055 grsecurity: add NixOS VM test 2016-01-24 04:06:19 +00:00
Tomas Vestelind
198c03bffe haka: very basic testing 2016-01-23 01:20:14 +01:00
Rok Garbas
109ba4c861 nixos: add test for postgresql, fixes #11146 2016-01-20 03:42:59 +01:00
Vladimír Čunát
716aac2519 Merge branch 'staging' into closure-size 2016-01-19 09:55:31 +01:00
aszlig
5caa8ab55e
nixos/tests/quake3: Don't quote +set arguments
With the new upstream Git version of ioquake3 introduced in 7fc7502, the
arguments to the quake3(server) binaries/wrappers may no longer be
passed as full single arguments (like "+set foo bar") but rather as
separate arguments (like "+set" "foo" "bar"), otherwise they will be
completely ignored.

Ran the x86_64-linux test on my machine and it now succeeds.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-01-16 01:13:36 +01:00
aszlig
c4de45b7ca
nixos/tests/quake3: Fix eval due to unfree license
Regression introduced by 6b447a3c9b.

In this commit the Quake 3 demo data now have a meta attribute which
specifies the license as unfreeRedistributable.

While I haven't found anything official about that on the web, let's
just allow it to be used in the test because first of all, we have been
using it for a long time (since 2009, introduced in 497760b) and second,
because it will be quite some effort to rewrite the test with something
like OpenArena (particularily because we need coverage data and need to
use the ioquake3 version plus OpenArena-specific patches).

Tested evaluation on my local system, but the VM test still fails.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2016-01-16 01:13:02 +01:00
Luca Bruno
27928a020a gnome3: default to gnome 3.18 2016-01-13 12:13:27 +00:00
Domen Kožar
82af770fa6 correctly fix 313fa2ebc6 2016-01-10 18:24:29 +01:00
Domen Kožar
313fa2ebc6 nixos installer tests: use -A nix-env flag to prevent out of memory 2016-01-10 17:48:35 +01:00
Robin Gloster
88292fdf09 jobs -> systemd.services 2016-01-07 06:39:06 +00:00
Dan Peebles
668179f31e tests.ec2-config: fix to not try to talk to the internet (which breaks on Hydra) 2016-01-07 03:25:56 +00:00
Tobias Geerinckx-Rice
82419575aa btrfsProgs -> canonical btrfs-progs 2016-01-03 20:38:44 +01:00
Benjamin Staffin
fe8498f609 nixos/mathics: New service and test 2016-01-02 14:34:55 -08:00
Vladimír Čunát
f9f6f41bff Merge branch 'master' into closure-size
TODO: there was more significant refactoring of qtbase and plasma 5.5
on master, and I'm deferring pointing to correct outputs to later.
2015-12-31 09:53:02 +01:00
Lancelot SIX
4994f0f7d0 slurm service: add tests 2015-12-25 15:55:07 +01:00
aszlig
4c61faa009
nixos/tests/networking: Add a test for loopback
It serves as a regression test, because right now if you enable
networking.useNetworkd the default loopback interface doesn't get
assigned any IP addresses.

To be sure, I have bisected this and it has been introduced with the
update to systemd 228 in 1da87d4.

Only the "scripted" networking tests have to succeed in order to trigger
a channel update of nixos-unstable, so I'm leaving this test as broken
and we have to figure out next what's the *exact* reason for the
breakage.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-12-18 07:09:42 +01:00
Luca Bruno
5b0352a6a4 Merge branch 'master' into closure-size 2015-12-11 18:31:00 +01:00
Thomas Tuegel
899c554f65 nixos/tests: test SDDM with KDE 5 enabled 2015-12-11 07:09:08 -06:00
Rodney Lorrimar
2198381235 nixos tests: pump.io: init 2015-12-06 13:35:21 +00:00
Emery Hemingway
2b6dcdfcd0 Rename 'emery' maintainer handle to 'ehmry', fixes #11493
Communication happens on Github so names should be consistent.
2015-12-05 23:06:20 +01:00
Luca Bruno
e0102a91ea nixos/tests: increase ram from 768 to 1024
Fixes simpleProvided test failing on unionfs
using more ram than available.

cc @edolstra @wkennington
2015-12-01 11:24:37 +01:00
Luca Bruno
bb88a11ee9 nixos/tests/misc: start systemd-udev-settle manually
systemd-udev-settle is not started by default anymore.
Because checking for psmouse like that is considered legacy,
we start systemd-udev-settle manually in the test.

cc @edolstra
2015-12-01 10:27:26 +01:00
Pascal Wittmann
763d89f9c5 tests-chromium: fix link to svg file
closes #11208
2015-11-29 22:43:28 +01:00
Luca Bruno
a412927924 Merge remote-tracking branch 'origin/master' into closure-size 2015-11-25 21:37:30 +01:00
Thomas Tuegel
314d3e52e8 add nixos/tests/sddm 2015-11-23 06:39:19 -06:00
Vladimír Čunát
333d69a5f0 Merge staging into closure-size
The most complex problems were from dealing with switches reverted in
the meantime (gcc5, gmp6, ncurses6).
It's likely that darwin is (still) broken nontrivially.
2015-11-20 14:32:58 +01:00
Nicolas B. Pierron
a5992ad61b Add a way to pin a NixOS version within the module system.
This modification add a way to re-evaluate the module system with a
different version of NixOS, or with a different set of arguments.
2015-11-19 20:58:45 +00:00
William A. Kennington III
8a44a36ca4 Merge branch 'master.upstream' into staging.upstream 2015-10-15 10:22:28 -07:00
Vladimír Čunát
99e4371526 curl: split into multiple outputs
Also use pkgconfig to be safer and fix (some) referrers.
2015-10-13 20:18:48 +02:00
Mathnerd314
faa82a676b gnome3 test: increase timeout
The gnome3 test has been failing recently ([1](http://hydra.nixos.org/build/26608126/nixlog/1/raw) [2](http://hydra.nixos.org/build/26605926/nixlog/1/raw)); this is due to exit code 124 which is [the command timing out](https://www.gnu.org/software/coreutils/manual/html_node/timeout-invocation.html).

This increases the timeout to 900, to align with the similar timeout in https://github.com/NixOS/nixpkgs/blob/master/nixos/lib/test-driver/Machine.pm#L222
2015-10-05 22:10:40 -06:00
Bjørn Forsman
5f17aeb403 nixos/docker: default storageDriver to "devicemapper"
Commit 9bfe92ecee ("docker: Minor improvements, fix failing test") added
the services.docker.storageDriver option, made it mandatory but didn't
give it a default value. This results in an ugly traceback when users
enable docker, if they don't pay enough attention to also set the
storageDriver option. (An attempt was made to add an assertion, but it
didn't work, possibly because of how "mkMerge" works.)

The arguments against a default value were that the optimal value
depends on the filesystem on the host. This is, AFAICT, only in part
true. (It seems some backends are filesystem agnostic.) Also, docker
itself uses a default storage driver, "devicemapper", when no
--storage-driver=x options are given. Hence, we use the same value as
default.

Add a FIXME comment that 'devicemapper' breaks NixOS VM tests (for yet
unknown reasons), so we still run those with the 'overlay' driver.

Closes #10100 and #10217.
2015-10-04 14:34:38 +02:00
William A. Kennington III
e7bb9e1023 Merge branch 'master.upstream' into staging.upstream 2015-09-30 13:26:04 -07:00
Luca Bruno
c6d77eb0bf nixos/tests/gnome3: wait for gnome shell to be started, for a better screenshot 2015-09-30 18:29:51 +02:00
William A. Kennington III
271972de0a Merge branch 'master.upstream' into staging.upstream 2015-09-29 15:54:33 -07:00
Eelco Dolstra
a924120340 Remove superfluous root resizing test
This is done in the EC2 test now.
2015-09-28 22:15:47 +02:00
Eelco Dolstra
f125d194e8 Test whether EC2 root volume resizing works 2015-09-28 22:15:47 +02:00
Eelco Dolstra
412477e914 Fix the EC2 test 2015-09-28 13:47:14 +02:00
aszlig
baf1d1dcd7
nixos/tests/virtualbox: Don't parallelize VM boot.
I'm not quite sure why the official Hydra gets a kernel panic in one of
two VMs using the exact same kernels:

https://hydra.nixos.org/build/26339384

Because the kernel panic happens before stage 1, let's wait for the
first VM to boot up and after the bootup is done, start the second one
in hope that it won't trigger the panic.

Oddly enough, whenever I run the test on my own Hydra and on my local
machines, I don't get anything like that.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-25 12:12:07 +02:00
Luca Bruno
45b1f5858c Merge branch 'gnome' into staging 2015-09-25 10:51:50 +02:00
Luca Bruno
26aea8b1aa gnome3: init 3.18 2015-09-25 10:48:41 +02:00
Eelco Dolstra
9d92bd7845 Add filesystem option to automatically grow to the maximum size
This is primarily for EC2 and other cloud environments, where the disk
may be bigger than the original image.
2015-09-24 19:59:44 +02:00
aszlig
764a767d5f
nixos/tests/virtualbox: Destroy detectvirt VM.
I forgot to do this in da0e642. It shouldn't be a big problem but it's
more clean to destroy the VM once we're done testing.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-24 09:16:21 +02:00
aszlig
3e6bb402b1
nixos/tests/virtualbox: Give VMs more memory.
We previously had 1024 MB of memory to fit a VirtualBox VM with 512 MB
plus the memory needed of the VirtualBox host VM. That obviously won't
work for two VirtualBox VMs, which are used for testing networking
between two VirtualBox guests.

Now, we have 2048 MB on the qemu guest (the VirtualBox host) and 768 MB
for each VirtualBox guest. That should be enough to fit in two
VirtualBox guests (I hope).

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-24 09:16:20 +02:00
aszlig
9a39c2e943
tests/virtualbox: Add a subtest for host USB.
Unfortunately, we can't test whether USB is really working, but we can
make sure that VirtualBox has access to the USB devices.

This is essentially testing #9736, which I haven't yet been able to
reproduce though, but it makes sense to test it so it won't happen in
future releases.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-21 22:32:13 +02:00
aszlig
da0e642c2b
tests/virtualbox: Add systemd-detect-virt subtest.
Addresses #9876 in the way that we want to make sure that VirtualBox 5.x
is going to be properly detected. Right now the result is "kvm", so the
subtest fails as expected with:

error: systemd-detect-virt returned "kvm" instead of "oracle" at (eval
       14) line 414, <__ANONIO__> line 92.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-17 16:02:43 +02:00
aszlig
effe0309ee
tests/virtualbox: Put name in log descriptions.
Makes it easier to debug and find out for which machine a certain log
socket has been started or stopped.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-17 12:31:59 +02:00
aszlig
29f535761a
tests/virtualbox: Use antiquotes for log sockets.
We're simply using antiquotation, since it's been a while since these
got introduced (in Nix 1.7). So we can use them because it makes the
code much more readable.

As usual, I made sure that I didn't accidentally change something in
functionality:

$ nix-instantiate nixos/tests/virtualbox.nix
...
/nix/store/cldxyrxqvwpqm02cd3lvknnmj4qmblyn-vm-test-run-virtualbox.drv
$ git stash pop
...
$ nix-instantiate nixos/tests/virtualbox.nix
...
/nix/store/cldxyrxqvwpqm02cd3lvknnmj4qmblyn-vm-test-run-virtualbox.drv
$

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-17 12:31:58 +02:00
aszlig
17f58275a0
tests/virtualbox: Fix long line in guestAdditions.
This is essentially not only "wrapping" the line but refactoring into a
shorter name which is used in two places.

And yes, I know I'm very pedantic if it comes to whitespaces and line
lengths, but I made sure this doesn't change any functionality:

$ nix-instantiate nixos/tests/virtualbox.nix
...
/nix/store/cldxyrxqvwpqm02cd3lvknnmj4qmblyn-vm-test-run-virtualbox.drv
$ git stash pop
...
$ nix-instantiate nixos/tests/virtualbox.nix
...
/nix/store/cldxyrxqvwpqm02cd3lvknnmj4qmblyn-vm-test-run-virtualbox.drv
$

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-17 12:31:58 +02:00
aszlig
8f98226f50
tests/virtualbox: Allow to call it with debug attr.
Instead of manually setting debug to true or false, this should make it
possible to now run the test like this:

nix-build nixos/tests/virtualbox.nix --arg debug true

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-17 12:31:58 +02:00
aszlig
0d4a3ce485
tests/virtualbox: Give test machines more memory.
Sometimes there are random kernel panics do to the lack of memory in the
qemu guests, but as we're setting the VirtualBox memory size relatively
low, 1024 MB should be enough for the qemu guests.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-16 00:19:52 +02:00
aszlig
7707c7df7f
tests/virtualbox: Start systemwide DBus in guests.
We want to check whether DBus functionality is working, so let's make
sure it is running in our mini-initrd.

DBus unfortunately requires to have users properly set up and another
configuration file other than in ${dbus.daemon}/etc/dbus-1/system.conf,
so we do provide that as well.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-09-16 00:19:52 +02:00
Luca Bruno
dfeee51818 nixos tests: add gdm test 2015-09-15 14:25:36 +02:00
Gabriel Ebner
50b1ca6dcc xdotool: 2.20110530.1 -> 3.20150503.1 2015-09-12 13:18:31 +02:00
Jaka Hudoklin
93132d1717 logstash service: fix tests 2015-09-06 15:20:56 +02:00
Jaka Hudoklin
a79d732243 etcd service: fix tests 2015-09-06 14:44:13 +02:00
Ragnar Dahlén
9bfe92ecee docker: Minor improvements, fix failing test
- Replace usage of deprecated CLI flag `--daemon`
- Introduce `storageDriver` option for module
- Fix failing test by using `overlay` storage driver
2015-09-04 00:23:38 +01:00
Eelco Dolstra
ea7b5bb8b0 Fix NFSv4 test
http://hydra.nixos.org/build/25349071
2015-09-01 12:00:04 +02:00
Eelco Dolstra
c839c988f4 Make proxy test more robust
http://hydra.nixos.org/build/25322489
2015-08-31 18:36:32 +02:00
Luca Bruno
38dd4f5ce1 gnome3 test: revert back to using slim
GDM needs more time to load on hydra, need a better way to find out
when the user has logged in.
2015-08-31 10:36:18 +02:00
Eelco Dolstra
1852e65776 Fix tests that use the Valgrind docs 2015-08-28 13:27:51 +02:00
Luca Bruno
119a6ef543 gnome3 test: use gdm with autologin instead of slim 2015-08-27 18:11:40 +02:00
Jascha Geerds
ab70c601b6 cups: Fix printing test 2015-08-27 09:24:45 +02:00
Eelco Dolstra
aa3b13549f Grmbl
http://hydra.nixos.org/build/24983009
2015-08-25 11:26:38 +02:00
Eelco Dolstra
779e585549 chromium: Fix test on i686-linux
http://hydra.nixos.org/build/24982682
2015-08-24 11:05:01 +02:00
Eelco Dolstra
d1c30dc5aa Give the chromium test more memory
Hopefully fixes random failures like

http://hydra.nixos.org/build/24861987/nixlog/446
2015-08-20 20:34:35 +02:00
aszlig
0ed0669699
nixos/tests/lightdm: Drop "session" screenshot.
Using waitForWindow on the IceWM root window doesn't necessarily mean
that the panel will be shown. In the lightdm test, we only make sure
that the login is working and thus it doesn't matter how the session
itself will look or whether IceWM is broken, so we don't need that
screenshot.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-08-20 12:57:40 +02:00
Tuomas Tynkkynen
f7771131b6 nixos/tests/lightdm: Fix waiting for the login to succeed
Currently the lightdm test detects a successful login by OCR'ing the
screen and searching for the clock widget's text.  Since the last
IceWM update (commit bdd20ced), either the font or the colors of the
clock changed such that the OCR doesn't pick it up anymore.

Instead, just look for a matching (root) window title, e.g.
"IceWM 1.3.9 (Linux/i686)"
2015-08-15 17:12:07 +03:00
aszlig
6440e9bbfd
nixos/vbox: Move all options to virtualisation.*.
Commit 687caeb renamed services.virtualboxHost to programs.virtualbox,
but according to the discussion on the commit, it's probably a better to
put it into virtualisation.virtualbox instead.

The discussion can be found here:

https://github.com/NixOS/nixpkgs/commit/687caeb#commitcomment-12664978

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-08-13 12:28:24 +02:00
William A. Kennington III
7a0980e5dc nixos/tests/openssh: Fix test by using safe public keys 2015-08-12 11:16:26 -07:00
Eelco Dolstra
2cd7c1f198 Unify NixOS and Nixpkgs channel structure
This is primarily to ensure that

  -I nixpkgs=https://nixos.org/channels/nixos-unstable/nixexprs.tar.xz

and

  -I nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/nixos-unstable.tar.gz

and

  -I nixpkgs=https://nixos.org/channels/nixpkgs-unstable/nixexprs.tar.xz

behave consistently.

It also allows installing packages via "nix-env -iA nixos.<pkg>"
rather than "nixos.pkgs.<pkg>". It would be even better to allow
"nixpkgs.<pkg>", but that requires a change to nix-channel.

Fixes #7659.
2015-08-05 17:37:11 +02:00
Eelco Dolstra
fc7e7f9032 Remove broken/unused test 2015-08-05 14:34:54 +02:00
Ricardo M. Correia
47dad51c2b nixos.tests.avahi: unmaintain 2015-08-04 17:30:55 +02:00
Vladimír Čunát
1b4a727959 nixos/tests/printing: unmaintain
I won't be a good maintainer of printing tests, as I don't print.
I don't know why I was made one in #8163, in the first place.
2015-08-04 13:17:44 +02:00
aszlig
07edb2483d
Merge branch 'vboxguest-sbin-removal'.
This removes all references to .../sbin for the guest additions and also
installs all binaries to .../bin instead (so no more .../sbin).

The main motivation for doing this is commit 98cedb3 (which
unfortunately had to be reverted in a9f2e10) and pull request #9063,
where the latter is an initial effort to move mount.vboxsf to .../bin
instead of .../sbin.

The commit I made afterwards is finishing the removal of .../sbin
entirely.
2015-08-04 04:00:09 +02:00
Charles Strahan
878e69c67c riak2: use sensible default paths
Make exporting the RIAK_{ETC,LOG,DATA}_DIR variables optional;
if they're not in the environment, we use the same default values as
NixOS.
2015-08-03 21:48:29 -04:00
aszlig
86b695a18e
vbox-guest: Remove all references to sbin/.
Using $storepath/sbin is deprecated according to commit 98cedb3, so
let's avoid putting anything in .../sbin for the guest additions.

This is a continuation of the initial commit done by @ctheune at
1fb1360, which unfortunately broke VM tests and only changed the path of
the mount.vboxsf helper.

With this commit, the VM test is fixed and I've also verified on my
machine that it is indeed working again.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-08-04 03:03:24 +02:00
Jascha Geerds
a7bfe5643b cups: Fix test by using different groff output 2015-07-27 20:15:34 +02:00
Charles Strahan
babb744b71 riak: new nixos service 2015-07-21 09:25:41 -04:00
Joachim Schiele
0731489953 all tests: added meta.maintainers section 2015-07-12 12:29:51 +02:00
William A. Kennington III
26e44a0a5c tests/boot: Remove unused store contents 2015-07-08 16:23:42 -07:00
William A. Kennington III
e861889e99 nixos/tests/installer: Add a testcase for fat32 /boot 2015-07-08 12:05:31 -07:00
Luca Bruno
6c8e6aaa24 nixos docker: fix service and test 2015-07-05 13:57:23 +02:00
aszlig
9bc2f77daa
nixos/tests/chromium: Improve sandbox checking.
We no longer need have "SUID sandbox" enabled in the chrome://sandbox
status page and we now also check for "You are adequately sandboxed." to
be absolutely sure that we're running with proper sandboxing.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-07-04 02:31:45 +02:00
Eelco Dolstra
f93d8425c3 Installer test: Fix booting from SCSI
This is required by the GRUB 1 test.
2015-06-17 15:47:43 +02:00
Dan Peebles
4b758e374e Initial attempt at configuring from EC2 userdata (with input from cstrahan). Now with VM tests! 2015-06-11 23:16:35 -04:00
Dan Peebles
b6c589b2da Simple EC2 user-data VM test 2015-06-11 22:54:04 -04:00
Eelco Dolstra
8e88710693 Installer test: Remove apparently useless setting of nix.readOnlyStore 2015-06-10 15:28:56 +02:00
Eelco Dolstra
d906939e74 Installer tests: Don't use the ISO
We already have separate tests for checking whether the ISO boots
correctly, so it's not necessary to do that here. So now
tests/installer.nix just tests nixos-install, from a regular NixOS VM
that uses the host's Nix store. This makes running the tests more
convenient because we don't have to build a new ISO after every
change.
2015-06-10 15:28:56 +02:00
Eelco Dolstra
7c6b935b60 Remove dead code 2015-06-03 16:38:52 +02:00
aszlig
d22b6fb10f
nixos: Add small VM test for lightdm.
Serves as a regression test for #7902.

It's not yet referenced in release(-combined)?.nix because it will fail
until the issue is resolved. Tested successfully against libgcrypt with
libcap passed as null however.

As for the test itself, I'm not quite sure whether checking for the time
displayed by IceWM is a good idea, but we can still fix that if it turns
out to be a problem.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-05-27 18:17:34 +02:00
William A. Kennington III
c8db08ee07 nixos/installer: Make test install disk larger to support the expressions 2015-05-25 21:11:59 -07:00
aszlig
5f50f23013
nixos/tests/chromium: Detect popup using OCR.
This will make the test a lot more reliable, because we no longer need
to press ESC multiple times hoping that it will close the popup.

Unfortunately in order to run this test I needed to locally revert the
gyp update from a305e6855d.

With the old gyp version however the test runs fine and it's able to
properly detect the popup.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-05-22 11:23:09 +02:00
aszlig
8be00dc71d
nixos/test-driver: Make tesseract OCR optional.
By default this is now enabled, and it has to be explicitely enabled
using "enableOCR = true". If it is set to false, any usage of
getScreenText or waitForText will fail with an error suggesting to pass
enableOCR.

This should get rid of the rather large dependency on tesseract which
we don't need for most tests.

Note, that I'm using system("type -P") here to check whether tesseract
is in PATH. I know it's a bashism but we already have other bashisms
within the test scripts and we also run it with bash, so IMHO it's not a
problem here.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-05-22 07:21:58 +02:00
aszlig
77d7aa6742
nixos/tests/luksroot: Switch to use waitForText.
Fixes the "blindly hope that 60 seconds is enough" issue from 1f34503,
so that we now have a (hopefully) reliable way to wait for the
passphrase prompt.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-05-21 19:55:21 +02:00
aszlig
1f34503010
nixos/tests/installer: Add test for LUKS rootfs.
This serves as a regression test for #7859.

It's pretty straightforward, except from the fact that nixos-generate-
config doesn't detect LUKS devices and the "sleep 60".

As for the former, I have tried to add support for LUKS devices for
nixos-generate-config, but it's not so easy as it sounds, because we
need to create a device tree across all possible mappers and/or LVM up
to the "real" device and then decide whether it is relevant to what is
currently mounted. So I guess this is something for the nixpart branch
(see #2079).

And the latter isn't very trivial as well, because the LUKS passphrase
prompt is issued on /dev/console, which is the last "console=..." kernel
parameter (thus the `mkAfter`). So we can't simply grep the log, because
the prompt ends up being on one terminal only (tty0) and using select()
on $machine->{socket} doesn't work very well, because the FD is always
"ready for read". If we would read the FD, we would conflict with
$machine->connect and end up having an inconsistent state. Another idea
would be to use multithreading to do $machine->connect while feeding the
passphrase prompt in a loop and stop the thread once $machine->connect
is done. Turns out that this is not so easy as well, because the threads
need to share the $machine object and of course need to do properly
locking.

In the end I decided to use the "blindly hope that 60 seconds is enough"
approach for now and come up with a better solution later. Other VM
tests surely use sleep as well, but it's $machine->sleep, which is bound
to the clock of the VM, so if the build machine is on high load, a
$machine->sleep gets properly delayed but the timer outside the VM won't
get that delay, so the test is not deterministic.

Tested against the following revisions:

5e3fe39: Before the libgcrypt cleanup (a71f78a) that broke cryptsetup.
69a6848: While cryptsetup was broken (obviously the test failed).
15faa43: After cryptsetup has been switched to OpenSSL (fd588f9).

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-05-21 13:21:41 +02:00
aszlig
3b396701fd
nixos/tests/installer: Allow pre-boot commands.
These commands will be executed directly after the machine is created,
so it gives us the chance to for example type in passphrases using the
virtual keyboard.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-05-21 13:21:41 +02:00
aszlig
5d2c6f0353
nixos/tests/installer: Allow to pass extra config.
We're going to need it for installer tests where nixos-generate-config
isn't yet able to fully detect the filesystems/hardware. for example for
device mapper configurations other than LVM.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-05-21 13:21:40 +02:00
Luca Bruno
25f9555599 Drop GNOME 3.12 2015-05-18 12:24:08 +02:00
Jascha Geerds
779b65f019 cups: Second attempt to fix our printing tests; add more sleep statements 2015-05-14 17:46:32 +02:00
Eelco Dolstra
15ffb9ad88 Remove fixed uid in tests 2015-05-13 16:23:57 +02:00
Jascha Geerds
92317259ef cups: First attempt to fix our printing tests; wait until cups is fully initialized 2015-05-13 14:22:30 +02:00
Jascha Geerds
6f69dd46d7 cups: Add defaultShared, browsing and webInterace config option 2015-05-10 13:46:32 +02:00
Jascha Geerds
65e2b83b36 cups: Fix printing tests
It seems like there's an upstream bug in the "lpstat" command. We need
to specify the server's port.

Further information: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=711327

[root@client:~]# lpstat -H
/var/run/cups/cups.sock

[root@client:~]# lpstat -h server -H
/var/run/cups/cups.sock:631

[root@client:~]# CUPS_SERVER=server lpstat -H
server:631

[root@client:~]# lpstat -h server:631 -H
server:631
2015-05-10 13:46:32 +02:00
Vladimír Čunát
30f31c9afc Merge 'master' into staging
(relatively simple conflicts)
2015-04-26 22:52:08 +02:00
Luca Bruno
db3b86560f GNOME 3.16.1, closes #7357 2015-04-25 12:02:33 +02:00
William A. Kennington III
793cf28cd5 nixos/tests/networking: Clean up and attempt to make more reliable 2015-04-10 23:23:53 -07:00
Eelco Dolstra
facd53315b tests/misc.nix: Ensure that the Nix DB is initialised correctly 2015-04-07 15:10:47 +02:00
aszlig
1165a243f8
nixos/tests/vbox: Make GUI startup more robust.
Sometimes, keys aren't properly recognized the first time, so in order
to make sure they get through, always resend the key again on retry.

In this case the worst that could happen is that the VM is started over
and over again, but never in parallel, so that's fine because we're
checking for successful startup 10 seconds after the keypress.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-04-04 17:09:15 +02:00
Eelco Dolstra
94eb519e19 Add nfs4 test 2015-04-02 17:44:48 +02:00
aszlig
82bd608de1
tests/chromium: Work around popup close flakiness.
It's not nice to send the escape key over and over again just to ensure
the popup is closed, because even *if* it fails to close the popup 4
times in a row it's just very unlikely that it will be closed. But in
order to make really sure, we might need to do a screenshot and detect
visual changes.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-04-02 14:12:19 +02:00
aszlig
56c0edca86
nixos/tests/swraid: Increase boot partition size.
I'm increasing it to 100MB to make sure, any bootloader will fit with
all its stages. Of course, right now the reason why GRUB doesn't fit
into the partition is because of mdadm 3.3.2 and thus the initrd taking
all the space, but in order to avoid confusion on why the *boot* loader
fails in the VM tests, I've increased the size.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-04-01 08:50:38 +02:00
Vladimír Čunát
81fc066900 Merge #4678: nixos iso-image: support USB booting
by using syslinux (i.e. support the dd-method in addition to unetbootin).
@vcunat tidied the PR by squashing closely related changes together.
2015-03-31 15:12:16 +02:00
William A. Kennington III
4868649f03 nixos/initrd: Generic library copying 2015-03-28 18:37:29 -07:00
William A. Kennington III
9d9a393a4b Merge pull request #6919 from ehmry/cjdns
cjdns: update pkg and fix nixos test
2015-03-25 22:16:23 -07:00
Jascha Geerds
164dbfff80 nixos/tests/printing: Fix CUPS service name (#6767) 2015-03-25 13:26:37 +01:00
Bob van der Linden
c57a912016 nixos: test: add tests for booting installation iso in various ways 2015-03-24 22:09:07 +01:00
Emery Hemingway
ba2074fc31 nixos/tests/cjdns: do not build cjdns at evaluation
Putting hostnames in the cjdns configuration requires a utility
be present to convert public keys to ip addresses
2015-03-21 10:17:48 -04:00
Jaka Hudoklin
2482b75eae kubernetes: update to 0.12.1, fix module 2015-03-18 14:37:03 +01:00
aszlig
19a7494600
nixos: Add VM test for i3 window manager.
Currently just makes sure that by default it's possible to open a
terminal.

And exactly this should be the main point that might confuse users of i3
in NixOS, because i3 doesn't print a warning/error if it is unable to
start the terminal emulator.

Thanks to @waaaaargh for reporting this issue.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-03-05 05:21:36 +01:00
aszlig
9de4caddc1
nixos/tests/chromium: Check new userns sandbox.
Since Chromium version 42, we have a new user namespaces sandbox in the
upstream project. It's more integrated so the chrome://sandbox page
reports it as "Namespace Sandbox" instead of SUID sandbox, which we were
re-using (or abusing?) in our patch.

So if either "SUID Sandbox" or "Namespace Sandbox" reports with "Yes",
it's fine on our side.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-02-22 07:52:53 +01:00
William A. Kennington III
23e1b46f17 nixos/tests/installer: Add all bootloaders to the store 2015-02-13 14:41:11 -08:00
William A. Kennington III
e2915fc5d1 nixos/tests: Fix installer test by providing a missing dependency 2015-02-12 11:36:02 -08:00
Bjørn Forsman
7a6af47cca nixos/tests/jenkins: increase timeout to 6 minutes
Fixes the test failure, at least on my system.
2015-02-10 16:50:50 +01:00
Jaka Hudoklin
ae34f923f7 panamax: simplify, refactor, add test 2015-02-07 15:32:20 +01:00
Vladimír Čunát
18380d2790 nixos/tests: fix printing after 0caae022fd 2015-02-05 10:51:47 +01:00
aszlig
eae32fb798
nixos/tests/chromium: Increase VM memory size.
Chromium is quite memory hungry and we frequently get random crashes in
the tests, so let's set it to 1024 MB because new releases of Chromium
most probably won't consume *less* memory.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2015-01-26 09:31:03 +01:00
Eelco Dolstra
efa8fc2b0a Paranoia 2015-01-15 18:37:55 +01:00
Jaka Hudoklin
b6198f08e3 nixos: add cadvisor service 2014-12-28 20:21:41 +01:00
Benjamin Staffin
c47cefd05e nixos/mesos: Parameterize mesos slave attributes
Added attributes to nixos/tests/mesos.nix to verify that mesos-slave
attributes work. If the generated attributes are invalid, the daemon
should fail to start.

Change-Id: I5511245add30aba658b1af22cd7355b0bbf5d15c
2014-12-18 14:47:24 -08:00
Eelco Dolstra
bf0f2adbeb Fix container test
http://hydra.nixos.org/build/17989795
2014-12-18 14:18:53 +01:00
aszlig
d45649b415
nixos/tests/virtualbox: Disable debug logging.
Especially if the user isn't in the vboxusers group anymore, this gets
VERY noisy, because the VBoxSVC process emits warnings for every single
USB device noting that it's only possible to access it when the user is
in the vboxusers group.

So, we now have a debug attribute, where we can enable it when
necessary.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-18 14:06:13 +01:00
aszlig
ef691d5c30
nixos/tests/virtualbox: Don't use vboxusers group.
At least when we're running in hardening mode, because it's needed there
only for USB support.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-18 14:06:13 +01:00
aszlig
2af435b5cd
nixos/tests/blivet: Fix by avoiding "nix-store".
The "nix-store" command within the VM test is running without
NIX_REMOTE=daemon and since Nix 1.8 tries to open the store database in
read-write mode even for nix-store -qR.

Now, we're doing this properly and rely on setup hooks, which is the
same method that's used when you're building a library which depends on
blivet.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-18 14:06:13 +01:00
Domen Kožar
d2462e2957 nixos/tests/gitlab.nix: set TimeoutStartSec to 10min
(cherry picked from commit 5bafb9cf0f)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-17 16:40:53 +01:00
aszlig
8bbf1dc80e
nixos/tests/virtualbox: Improve logging.
This also makes showvminfo obsolete, as we get the same information from
the hosts log.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-15 19:17:38 +01:00
aszlig
d85fabd68c
nixos/virtualbox/hostonlyif: Fix writing to /root.
Creates unnecessary cruft in the root users home directory, which we
really don't need. Except the log, but therefore we now cat the log to
stderr and the private temporary directory is cleaned up afterwards.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-15 19:16:43 +01:00
aszlig
9bf16a9c33
nixos/tests/virtualbox: Add test for hostonlyif.
Essentially adds two more VirtualBox VMs to the test and also increases
the memory size of the qemu VM to 768 MB to make sure we don't run out
of memory too soon.

We're testing whether those two VMs can talk to either each other
(currently via ICMP only) or to/from the host via TCP/IP.

Also, this restructures the VM test a bit, so that we now pass in a
custom stage2Init script that has access to the store via a private
mount over the /nix/store that's already in the initrd. The reason why
this is a private mount is that we don't want to shadow the Nix store of
the initrd, essentially breaking cleanup functionality after the custom
stage 2 script (currently this is only "poweroff -f").

Note that setting the hostname inside the VirtualBox VM is *not* for
additional fanciness but to produce a different store path for the VM
image, so that VirtualBox doesn't bail out when trying to use an image
which is already attached to another VM.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-15 17:52:20 +01:00
aszlig
77831e8467
nixos/tests/virtualbox: Generalize expression.
We're going to create more than one VirtualBox VM, so let's dynamically
generate subs specific to a particular VirtualBox VM, merging everything
into the testScript and machine expressions.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-15 17:52:16 +01:00
Domen Kožar
d62d45642c fix quake3 test
(cherry picked from commit fde7e1286e)
Signed-off-by: Domen Kožar <domen@dev.si>
2014-12-14 13:47:19 +01:00
Jaka Hudoklin
6ae50a4cc6 nixos/kubernetes: fix test, make more deterministic by having more ram 2014-12-14 13:05:35 +01:00
Domen Kožar
ba5fad6dfa Merge pull request #5323 from offlinehacker/gitlab_i686_fix
gitlab: fix i686-linux build and module
2014-12-14 09:48:44 +01:00
Jaka Hudoklin
bbc44bf0da nixos/gitlab: imporove tests 2014-12-14 02:30:13 +01:00
aszlig
69858d7743
nixos: Add VM test for VirtualBox.
Currently it pretty much tests starting up virtual machines and just
shutting down afterwards, but for both VBoxManage and the VirtualBox
GUI.

This helps catching errors in hardened mode, however we still need to
test whether networking works the way intended (and I fear that this is
broken at the moment).

The VirtualBox VM is _not_ using hardware virtualization support (thus
we use system = "i686-linux", because x86_64 has no emulation support),
because we're already within a qemu VM, which means it's going to be
slow as hell (that's why I've written own subs just for testing
startup/shutdown/whatnot with respective timeouts).

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-12-13 11:43:44 +01:00
Jaka Hudoklin
13e58784bf nixos/gitlab: fixes
- fix timezone data not found
- fix module, add simple test
- allow to set port
2014-12-12 18:01:31 +01:00
Jaka Hudoklin
91961c2a32 nixos/mesos: fix typo 2014-12-11 23:35:39 +01:00
Jaka Hudoklin
4be1089781 nixos: move kubernetes & fleet to services/cluster 2014-12-11 23:32:37 +01:00
Eelco Dolstra
faf0797c0c Use https://cache.nixos.org 2014-12-09 13:38:46 +01:00
Domen Kožar
45ec582372 nixos.tests.bittorrent: mark torrent as private
Hopefully that resolves transient errors with DHT
such as http://hydra.nixos.org/build/17784957
2014-12-09 12:08:58 +01:00
Jaka Hudoklin
4a993dc409 Merge pull request #5255 from offlinehacker/nixos/fleet
nixos: add fleet module
2014-12-08 02:49:42 +01:00
Jaka Hudoklin
b7092dc95c nixos: add fleet module 2014-12-07 21:52:52 +01:00
Domen Kožar
07ce825a4e installer tests: don't rely on swap.target until systemd bug is fixed 2014-12-07 20:58:48 +01:00
Jaka Hudoklin
1b8516b498 nixos/kubernetes: fix tests 2014-12-07 12:49:06 +01:00
Domen Kožar
226d209d97 fix installer tests 2014-12-05 18:31:30 +01:00
William A. Kennington III
6ad032ed93 nixos/installer: Fix swap device override 2014-12-04 13:34:35 -08:00
William A. Kennington III
82f59e8c69 nixos/installer: Override swap devices so tests don't fail
This patch should be reverted if either:
  - systemd fixes the multi-swapon issue.
    https://bugs.freedesktop.org/show_bug.cgi?id=86930
  - If we disable the autogeneration of swap and vfat units within
    systemd.
2014-12-03 15:43:48 -08:00
Georges Dubus
2a7808138d whitespace change to restart kde4 test 2014-12-03 17:18:33 +01:00
Domen Kožar
7a140096e0 whitespace change for kde4 test to force rebuild :( 2014-12-03 12:31:10 +01:00
William A. Kennington III
75ead8812b nixos/tests: Fix nfs 2014-12-02 01:34:20 -08:00
William A. Kennington III
2b06a92c2a nixos/nfs: Fix dependency ordering 2014-12-01 17:19:44 -08:00
Jaka Hudoklin
40d73c5eb7 nixos/docker: fix module, add simple test 2014-12-01 17:20:35 +01:00
Jaka Hudoklin
3424ded286 nixos: add peerflix module 2014-12-01 16:42:40 +01:00
Antoine R. Dumont
3c7e779602 Introduce a dedicated networking.proxy option
Following the discussion NixOS#5021:
- obsolete the nix.proxy option
- add the networking.proxy option
- open a default no_proxy environment variable
- add a rsync option
- Manual tests ok.
- Automatic tests ok.

Amended by lethalman to simplify the option descriptions.
2014-11-30 15:19:25 +01:00
William A. Kennington III
9a11132fe5 nixos/network: Remove debug output in tests 2014-11-30 01:21:37 -08:00
William A. Kennington III
7ecb084b77 nixos/networking: More fixes 2014-11-29 22:35:03 -08:00
William A. Kennington III
bcfe7b2200 Merge pull request #5043 from wkennington/master.networkd
nixos/networking: Revamp networking configuration and add an experimental networkd option.
2014-11-29 19:59:31 -08:00
William A. Kennington III
a403379b88 nixos/tests: Add networking tests for basic functionality 2014-11-29 19:53:37 -08:00
Jaka Hudoklin
20487919b2 nixos/kubernetes: try to fix test by incrising memory size 2014-11-30 01:36:10 +01:00
Jaka Hudoklin
2b261c1edf nixos: add kubernetes module 2014-11-29 02:27:17 +01:00
Domen Kožar
28a1af6e06 fix printing test 2014-11-27 20:01:18 +01:00
Aristid Breitkreuz
82f2be6a26 containers: add test that stopping and starting a container works (#4989) 2014-11-24 23:19:34 +01:00
Jaka Hudoklin
4f592d4f29 nixos/etcd: fix postStart check and make tests deterministic 2014-11-23 12:16:50 +01:00
Jaka Hudoklin
73dc767aa0 nixos: add docker-registry module 2014-11-22 12:16:41 +01:00
Jaka Hudoklin
b3bc157f7f nixos: add etcd module 2014-11-21 13:54:45 +01:00
aszlig
ad87aef2ab
nixos/tests/chromium: Allow to override packages.
Of course, this could be done via packageOverrides, but this is more
explicit and makes it possible to run the tests with various Chromium
overrides.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-11-19 15:54:19 +01:00
aszlig
0e4c1cc066
nixos: Add rudimentary VM tests for Chromium.
Currently, the test is only for testing the user namespace sandbox and
even that isn't very representative, because we're running the tests as
root.

But apart from that, we should have functionality for opening/closing
windows and the main goal here is to get them as deterministic as
possible, because Chromium usually isn't very nice to chained xdotool
keystrokes.

And of course, the most important "test" we have here: We know at least
whether Chromium works _at_all_.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-11-18 18:41:56 +01:00
Luca Bruno
e8adc8b5ec Drop GNOME 3.10 2014-11-14 22:46:37 +01:00
Luca Bruno
6af0d6974f Merge branch 'master' into staging 2014-11-10 10:03:52 +01:00
Emery Hemingway
67a2a58314 cjdns: service tweaks, new NixOS test 2014-11-08 23:39:02 +01:00
Luca Bruno
83221f3886 Merge branch 'master' into staging
Makes the build more useful:
- Disabled hybrid iso, makes installer tests pass again
- Imagemagick fixes to the "Illegal instruction" thing
2014-11-08 15:56:40 +01:00
Eelco Dolstra
b3eb981a95 apache-httpd: Make 2.4 the default
The NixOS 14.11 release is a good time to finally make 2.4 the
default.
2014-11-06 14:55:44 +01:00
Vladimír Čunát
52404a868d Merge recent master into staging
Nixpkgs Hydra: ?compare=1157272

TODO: port e22889064f

Conflicts:
	nixos/tests/gnome3_10.nix (auto-solved)
	pkgs/applications/video/aegisub/default.nix
	pkgs/development/libraries/boost/1.55.nix
2014-11-05 15:00:44 +01:00
Eelco Dolstra
c7ee917197 Fix tests.runInMachine evaluation 2014-11-04 14:28:09 +01:00
Luca Bruno
5d2b3ff8cf nixos: increase allocated memory for gnome tests. Closes #4651 2014-11-02 16:33:10 +01:00
Vladimír Čunát
2cf17b0802 Merge recent master into staging
Hydra nixpkgs: ?compare=1156478
2014-10-23 17:40:41 +02:00
aszlig
78ef5f9c14
nixpart: Move all 0.4 dependencies into one dir.
Once nixpart 1.0 is released we then only need to delete one single
directory rather than searching for needles in a haystack, that is, all
of <nixpkgs>. Also, it keeps my sanity at an almost healthy level.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-10-22 08:22:59 +02:00
aszlig
7676ff5973
nixpart: Bring back requirements for version 0.4.
Quite a mess but at least the mdraid tests succeed now. However, the
lvm2 tests are still failing, so we need to bring back a few more old
crap :-(

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-10-22 08:22:58 +02:00
aszlig
9d2e514f46
nixos/tests/partition: Fix typo in F2FS tests.
Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-10-22 08:22:58 +02:00
aszlig
cff26e2d38
nixos: Add VM test for blivet.
I'm really not sure whether these tests are actually run upstream,
because there are quite a few oddities which either are my fault by just
missing something important or upstream really doesn't bother to run
those tests.

One example of this are testDiskChunk1 and testDiskChunk2, which create
two non-existing partitions and tries to allocate them. Now, in
allocatePartitions(), the partedPartition attributes are reset to None
and shortly afterwards a for loop is expecting it to be NOT None.

So, for now I'm disabling these tests and will see if we stumble on them
during work on nixpart 1.0, so we're really sure whether it's my fault
or a real bug in blivet.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-10-22 08:22:58 +02:00
aszlig
cb2c34f1bb
blivet: Update to new upstream version 0.67.
Put a copy of old version 0.17 expression into 0.17.nix and update the
pointers from nixpart0 accordingly.

This also means, that plain nixpart is now way more broken than
nixpart0 (we might want to temporarily fix 0.4 anyway).

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-10-22 08:22:57 +02:00
Eelco Dolstra
09dc132e04 Merge remote-tracking branch 'origin/master' into staging
Conflicts:
	pkgs/development/libraries/poppler/default.nix
2014-10-16 15:16:50 +02:00
Domen Kožar
4941b96f0c eval fix 2014-10-07 21:46:15 +02:00
Shea Levy
92837f2dbf Ditch efi installer tests
They've been broken forever due to weirdness in qemu tests, and they don't add much over installer tests
2014-10-07 12:20:56 -04:00
Domen Kožar
b0b9e5d50c tests.bittorrent: use opentracker as bittorrent tracker 2014-10-07 17:22:42 +02:00
Eelco Dolstra
a85dcf4a00 Merge remote-tracking branch 'origin/master' into staging
Conflicts:
	pkgs/development/libraries/libav/default.nix
	pkgs/shells/bash/bash-4.2-patches.nix
	pkgs/stdenv/generic/default.nix
2014-10-07 00:09:37 +02:00
Eelco Dolstra
7f043ffbbe tests/kde4.nix: Don't build kdeedu
This prevents a dependency on liblapack (which randomly fails) and
TeXlive (which is huge).

http://hydra.nixos.org/build/14897240
(cherry picked from commit b9bde98161)
2014-09-29 13:32:55 +02:00
Domen Kožar
63280c511e nixos: munin/jenkins: specify timeout correctly 2014-09-28 14:25:11 +02:00
Domen Kožar
1e05bbaa96 nixos: increase timeout for jenkins/munin systemd services 2014-09-27 23:28:49 +02:00
Eelco Dolstra
0a967b9268 Installer test: Use the minimal ISO
So we don't depend on KDE etc. (which we don't even test here).
2014-09-25 00:07:35 +02:00
William A. Kennington III
8250059a9f nixos/tests/nat: Add tests for standalone and firewall based nat 2014-09-18 14:39:46 -07:00
William A. Kennington III
b047f2ddec nixos/tests/nat: Modify test to accomodate for firewall consolidation 2014-09-18 11:28:58 -07:00
Vladimír Čunát
d957b4bd78 Merge recent master into staging
Hydra nixpkgs: ?compare=1151601
2014-09-13 21:48:29 +02:00
aszlig
d394d095ab
containers: Don't descend into mounts on destroy.
This tells the sad tale of @the-kenny who had bind-mounted his home
directory into a container. After doing `nixos-container destroy` he
discovered that his home directory went from "full of precious data" to
"no more data".

We want to avoid having similar sad tales in the future, so this now also
check this in the containers VM test.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-09-11 18:12:35 +02:00
Luca Bruno
e4e39f26ba Change default from gnome 3.10 to gnome 3.12 2014-09-08 18:35:45 +02:00
Eelco Dolstra
585983bc95 Merge remote-tracking branch 'origin/staging'
Conflicts:
	pkgs/applications/version-management/subversion/default.nix
2014-09-08 11:42:09 +02:00
Domen Kožar
130e56cd42 nixos.tests.gnome3: wait 20sec for the screenshot 2014-09-07 14:51:10 +02:00
Vladimír Čunát
06fea81c6e Merge recent master into staging
Hydra: ?compare=1150594
2014-09-06 16:52:45 +02:00
Thomas Tuegel
53fa517176 Merge pull request #3961 from wkennington/master.grub
nixos/install-grub: Read correct mountpoints
2014-09-05 20:01:08 -05:00
Eelco Dolstra
0dc8d73d17 Fix munin test evaluation 2014-09-06 00:54:40 +02:00
Domen Kožar
b420eeba44 remove bittorrent package since it's obsolete 2014-09-05 22:49:31 +02:00
William A. Kennington III
6fb6ba48f8 nixos/installer-test: nixos-option syntax correction 2014-09-05 09:49:05 -07:00
William A. Kennington III
e07e1c3fdf nixos/installer-test: Add writable store test 2014-09-05 09:48:58 -07:00
Eelco Dolstra
59edfd61ad Increase systemd timeout on Jenkins and Munin tests
These were timing out a lot.

http://hydra.nixos.org/build/13991108
http://hydra.nixos.org/build/13991107
2014-09-05 15:50:55 +02:00
Eelco Dolstra
daebba2c97 Fix container test 2014-09-05 14:08:35 +02:00
aszlig
c9d1c0d8d1
nixos/tests: Add basic test for nsd module.
Currently only tests basic resource record lookup against IPv4 and IPv6.
Nothing special yet, but probably enough for most setups.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-09-05 02:54:39 +02:00
Strahinja Popovic
fe3f7716f0 Enabled access to binaries of needed tools, and worker daemons can be enabled for phabricator #3306 2014-09-03 15:46:59 +04:00
William A. Kennington III
4eff4afa3c nixos/installer-test: Use nested subvolumes for root to test detection 2014-09-02 09:16:13 -07:00
William A. Kennington III
3944239362 nixos/tests-installer: Add a test for btrfs default volumes and bind mounts 2014-09-02 09:16:13 -07:00
William A. Kennington III
36614ff3e2 Revert "Revert "Merge pull request #2449 from wkennington/master.grub""
This reverts commit 94205f5f21.

Conflicts:
	nixos/modules/system/boot/loader/grub/install-grub.pl
2014-09-02 09:16:13 -07:00
Peter Simons
1c0d15b90e Merge branch 'origin/master' into staging.
Conflicts:
	pkgs/development/libraries/ffmpeg/2.x.nix
	pkgs/development/libraries/serf/default.nix
2014-09-02 12:31:03 +02:00
William A. Kennington III
3e834e1783 nixos/tests: Fix usage of head function without pkgs.lib 2014-09-01 04:39:45 -07:00
William A. Kennington III
3d037ebb94 Revert "Revert "Merge pull request #3182 from wkennington/master.ipv6""
This reverts commit ea8910652f.
2014-08-31 09:46:16 -07:00
Rob Vermaas
ea8910652f Revert "Merge pull request #3182 from wkennington/master.ipv6"
This reverts commit b23fd65854, reversing
changes made to 43654cba2c.
2014-08-31 10:58:54 +02:00
Michael Raskin
94205f5f21 Revert "Merge pull request #2449 from wkennington/master.grub"
This reverts commit 469f22d717, reversing
changes made to 0078bc5d8f.

Conflicts:
	nixos/modules/installer/tools/nixos-generate-config.pl
	nixos/modules/system/boot/loader/grub/install-grub.pl
	nixos/release.nix
	nixos/tests/installer.nix

I tried to keep apparently-safe code in conflicts.
2014-08-31 12:58:37 +04:00
William A. Kennington III
86c0f8c549 Refactor nixos files relying on the old ipAddress / prefixLength / subnetMask attributes 2014-08-30 07:33:38 -07:00
Vladimír Čunát
e51f73652d Merge recent master into staging
Hydra: ?compare=1149952

Conflicts:
	nixos/doc/manual/configuration.xml (changed split file)
	nixos/modules/config/users-groups.nix (choosing filterNull instead of inline definition)
	pkgs/development/libraries/readline/readline6.3.nix (auto-solved)
2014-08-30 10:04:02 +02:00
Luca Bruno
01f0b1cf1a Fix evaluation of nixos tested 2014-08-29 11:49:36 +02:00
William A. Kennington III
cc62623b37 tests/installer: Provided test should add symlinks to /dev/disk if udev doesn't 2014-08-28 13:35:36 -07:00
William A. Kennington III
4f096c044f nixos/grub: Simplify detection of labels / uuids for provided device names 2014-08-28 13:35:36 -07:00
William A. Kennington III
6549bcff96 tests/installer: Fix provided test uuid and label mounts 2014-08-28 13:35:36 -07:00
William A. Kennington III
b651097d19 tests/installer: Swapspace should be larger 2014-08-28 13:35:36 -07:00
William A. Kennington III
7264941a46 tests/installer: Remove unneeded tests 2014-08-28 13:35:36 -07:00
William A. Kennington III
429f785135 tests/installer: Fix simple tests 2014-08-28 13:35:36 -07:00
William A. Kennington III
8ff4b3b780 tests/installer: Add swap to the new tests 2014-08-28 13:35:36 -07:00
William A. Kennington III
8b36bf5c59 tests/installer: fix mount 2014-08-28 13:35:36 -07:00
William A. Kennington III
62fedf6081 installer/btrfs: Typo in subvol 2014-08-28 13:35:35 -07:00
William A. Kennington III
2b703f82d5 tests/installer: Test for more grub configurations 2014-08-28 13:35:35 -07:00
William A. Kennington III
809caa87ab tests/installer: Add btrfs tests for grub and nixos-generate-config 2014-08-28 13:35:35 -07:00
Eelco Dolstra
619f18956d Bump the amount of memory for the installer test
It randomly OOMs.

http://hydra.nixos.org/build/13587153
2014-08-25 10:54:10 +02:00
Eelco Dolstra
a323d146b7 Add user attribute isNormalUser
This is shorthand for setting group, createHome, home, useDefaultShell
and isSystemUser.
2014-08-15 02:16:04 +02:00
Eelco Dolstra
c7ca46904f tests/ipv6.nix: Fix race
http://hydra.nixos.org/build/13119647
2014-08-10 14:51:23 +02:00
Eelco Dolstra
f94f659a31 Don't require a device for tmpfs filesystems 2014-07-30 13:18:33 +02:00
Eelco Dolstra
19fc92a8ed nixos/tests/containers.nix: Don't ping
This randomly fails with "Destination Host Unreachable". That
shouldn't happen, since all interfaces/routes should be up after
"nixos-container start" returns. Need more investigation...
2014-07-29 15:34:22 +02:00
Luca Bruno
cb41fecaa1 Try fixing the nixos mumble tests, again 2014-07-02 11:28:43 +02:00
Eelco Dolstra
b8cb960a58 Fix evaluation 2014-07-01 16:28:34 +02:00
Florian Friesdorf
9b7dbcc83e name nixos tests, close #3078 2014-06-28 16:05:47 +02:00
aszlig
865787ef32
nixos/tests/openssh: Test configured auth keys.
So far the test only uses an authorized key that is copied over to the
target machine instead of being set by the target's configuration.

Now, we cover both cases.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2014-06-27 08:52:03 +02:00
William A. Kennington III
ef4ea24420 sudo: Always keepVisudo in order to simplify sudo build 2014-06-17 22:41:32 -05:00
Ricardo M. Correia
f8e108c865 nixos.tests.installer: Fix test failures due to network being disabled 2014-06-17 18:41:26 +02:00
Eelco Dolstra
13befa3979 Set session variables in the shell as well 2014-06-13 18:34:56 +02:00
Ricardo M. Correia
abd0b3f411 nixos.tests.installer: Attempt to fix race condition
Attempt to fix race condition in installer tests, especially the
grub1 test.

The latter was failing when running "parted /dev/sda ..." because
/dev/sda didn't exist yet.
2014-05-30 21:26:24 +02:00
Jaka Hudoklin
66456c0798 nixos: add influxdb module 2014-05-27 22:56:36 +02:00
Eelco Dolstra
0bc7ec6e28 Remove obsolete udisks test
Closes #2716.
2014-05-22 12:11:53 +02:00
Luca Bruno
927b385cc9 Fix mumble test: wait for X windows to appear, not only sleep 2014-05-21 18:09:21 +02:00
Eelco Dolstra
f23231f198 Installer test: Don't wait for dhcpcd if we don't have a network 2014-05-21 15:55:50 +02:00
Eelco Dolstra
ca123bc274 Installer test: Get rid of a warning 2014-05-21 15:55:50 +02:00
Eelco Dolstra
35925d7a76 Fix installer test
The installer now asks the user to set a root password if stdin is a
tty, which doesn't work for an interactive test.

http://hydra.nixos.org/build/11130072
2014-05-21 11:04:45 +02:00
Luca Bruno
af3d1ad06d Add gnome 3.12 test 2014-05-20 13:41:41 +02:00
Austin Seipp
2558fa587b Merge pull request #2629 from letac/master
Phabricator, a web application, snapshot of 2014-05-12
2014-05-14 14:57:36 -05:00
Corey O'Connor
5112e6476b resolve issue #2308 2014-05-13 11:11:34 +02:00
Strahinja Popovic
25e0d51a67 Phabricator, a web application, snapshot of 2014-05-12 2014-05-12 19:59:40 +02:00
Emery Hemingway
c96d5fe170 nixos: f2fs filesystem module support (close #2085) 2014-05-11 13:53:26 +02:00
Eelco Dolstra
fae135b871 Installer test: Increase amount of RAM
On x86_64, 384 MB is not enough anymore for running "nix-env -i".

http://hydra.nixos.org/build/10865007
2014-05-07 18:24:15 +02:00
Eelco Dolstra
27d47f3983 Fix the simple installer test
http://hydra.nixos.org/build/10712818
2014-04-30 15:07:34 +02:00
Eelco Dolstra
437962ebb2 Installer test: Unmount filesystems after installation
Hopefully fixes failures like:

  http://hydra.nixos.org/build/10712833

This shouldn't be necessary, but it might be that the use of unionfs
is interfering with a clean shutdown.
2014-04-30 15:07:34 +02:00
Eelco Dolstra
9bb209a3bd gummiboot: Automatically disable GRUB 2014-04-30 11:47:18 +02:00
Eelco Dolstra
e9be441b62 Merge the EFI test into tests/installer.nix 2014-04-30 11:26:39 +02:00
Eelco Dolstra
077ecf43e5 Installer test: Remove fileSystems argument
The config function unintentionally ignored its fileSystems
argument. However, things still worked thanks to the magic of
nixos-generate-config. Yay!
2014-04-30 11:26:39 +02:00
Eelco Dolstra
501d532188 Add a test for automounting 2014-04-29 15:34:55 +02:00
Eelco Dolstra
7ddcd7b6b6 Give the KDE test more memory 2014-04-25 17:27:05 +02:00
Eelco Dolstra
c52fb449f4 Urgh
Can't figure out why "hostname -s" keeps failing randomly :-(

http://hydra.nixos.org/build/10662142
2014-04-25 00:30:33 +02:00
Eelco Dolstra
b8d59765e1 cups: Add a listenAddresses option 2014-04-25 00:30:12 +02:00
Eelco Dolstra
23297b0edd Make nscd startup synchronous
Nscd forks into the background before it's ready to accept
connections. So explicitly wait until it's ready.

http://hydra.nixos.org/build/10661767
2014-04-24 23:18:47 +02:00
Eelco Dolstra
d7a7f80aff cups: Start after network.target
http://hydra.nixos.org/build/10661709
2014-04-24 23:18:16 +02:00
Eelco Dolstra
af817ae0d8 Try again 2014-04-24 18:32:32 +02:00
Eelco Dolstra
2b7e746c02 Make the misc test a bit more robust 2014-04-24 15:19:26 +02:00
Ricardo M. Correia
3ad27289fc nixos/tests/avahi: Fix race condition on mDNS test 2014-04-21 19:54:16 +02:00
Eelco Dolstra
894e2dfb25 Add a test for udisks2 2014-04-19 14:37:05 +02:00
Eelco Dolstra
9f65e82b59 Make the login test a bit more robust
http://hydra.nixos.org/build/10397037
2014-04-18 01:22:38 +02:00
Eelco Dolstra
560a1103ad Add option ‘systemd.tmpfiles.rules’
This allows specifying rules for systemd-tmpfiles.

Also, enable systemd-tmpfiles-clean.timer so that stuff is cleaned up
automatically 15 minutes after boot and every day, *if* you have the
appropriate cleanup rules (which we don't have by default).
2014-04-17 16:14:56 +02:00
Eelco Dolstra
518f710547 Fix module loading in systemd-udevd 2014-04-17 12:26:12 +02:00
Eelco Dolstra
eeb32fd82b Hopefully fix random failure in cups test
http://hydra.nixos.org/build/10372895
2014-04-17 10:53:08 +02:00
Eelco Dolstra
c382ad1e17 Fix tests
Doing a =~ regexp check doesn't do anything in itself...
2014-04-16 16:09:32 +02:00
Eelco Dolstra
06edd48842 Fix the bittorrent test
This was broken since e8baaba044,
because on the tracker, a DNS lookup for "tracker" returns ::1 due to
nss_myhostname. This apparently confused it.
2014-04-15 14:37:20 +02:00
Eelco Dolstra
269bd7ef83 Add missing file 2014-04-14 21:03:43 +02:00
Eelco Dolstra
4f2aa2f706 Fix installer test evaluation 2014-04-14 16:24:08 +02:00
Eelco Dolstra
abe218950c Make it easier to run the tests
You can now run a test in the nixos/tests directory directly using
nix-build, e.g.

  $ nix-build '<nixos/tests/login.nix>' -A test

This gets rid of having to add the test to nixos/tests/default.nix.
(Of course, you still need to add it to nixos/release.nix if you want
Hydra to run the test.)
2014-04-14 14:02:44 +02:00
Eelco Dolstra
13185280fe Fix tests broken due to the firewall being enabled by default 2014-04-11 17:16:44 +02:00
Eelco Dolstra
d2155649af Merge branch 'containers'
Fixes #2105.
2014-04-10 15:55:51 +02:00
Eelco Dolstra
2f51ca9609 Add a regression test for udisks 2014-04-07 13:22:12 +02:00
Eelco Dolstra
819e7c9fbd Add a test for NixOS containers 2014-04-03 16:36:24 +02:00
Austin Seipp
788354cc34 nixos: add mumble test
This tests that both the client and server work. With screenshots!

Signed-off-by: Austin Seipp <aseipp@pobox.com>
2014-04-02 03:55:37 -05:00
Eelco Dolstra
c20383e756 Another fix to the installer tests 2014-03-31 11:10:56 +02:00
Eelco Dolstra
075168ca81 nixos-hardware-scan: Detect QEMU 2014-03-30 17:27:18 +02:00
Eelco Dolstra
1c192e1fea Another attempt to fix the installer test
http://hydra.nixos.org/build/9904133
2014-03-30 16:53:23 +02:00
Jaka Hudoklin
227997d8ca nixos/rabbitmq: rewrite
- rewrite from old jobs options to new services
- add simple test
- add dataDir option
2014-03-29 10:56:07 +01:00
Corey O'Connor
40de28afca remove users.jenkins config start on slave config.
Uses standard NixOS user config merging.
Work in progress: The slave config does not actually start the slave agent. This just configures a
jenkins user if required. Bare minimum to enable a nice jenkins SSH slave.
2014-03-13 13:01:50 -07:00
Corey O'Connor
9b79d5b298 Add jenkins continuous integration server and user.
By default the jenkins server is executed under the user "jenkins". Which can be configured using
users.jenkins.* options. If a different user is requested by changing services.jenkins.user then
none of the users.jenkins options apply.

This patch does not include jenkins slave configuration. Some config options will probably change
when this is implemented.

Aspects like the user and environment are typically identical between slave and master. The service
configs are different. The design is for users.jenkins to cover the shared aspects while
services.jenkins and services.jenkins-slave cover the master and slave specific aspects,
respectively.

Another option would be to place everything under services.jenkins and have a config that selects
master vs slave.
2014-03-13 13:01:49 -07:00
Eelco Dolstra
497997cc38 Move generation of coverage reports from nixos/lib/testing to releaseTools
Also, turn some stdenv adapters into setup hooks.
2014-03-03 13:57:08 +01:00
Eelco Dolstra
1d9cd24d0b Fix mysql-replication test 2014-02-28 16:18:31 +01:00
Eelco Dolstra
da2a336a3c Remove tabs 2014-02-28 16:18:31 +01:00
Shea Levy
691f6c4c59 Fix mysql test evaluation 2014-02-28 06:16:57 -05:00
Shea Levy
258c7536be Force a rebuild 2014-02-09 11:59:02 -05:00
Domen Kožar
028379be28 nixos: add most basic gnome3 test and take a screenshot 2014-02-08 21:47:39 +01:00
Domen Kožar
ee14f8da9a remove references to isSystemUser and fix eval of tested job 2014-02-08 21:10:00 +01:00
Shea Levy
741cc62f75 Force a rebuild.
Sigh.

Signed-off-by: Shea Levy <shea@shealevy.com>
2014-02-04 08:43:45 -05:00
Shea Levy
51de280c0a nixos X tests: wait for logind to link a session to the server
There seems to be some race causing failures if an X command gets in before slim starts the session

Signed-off-by: Shea Levy <shea@shealevy.com>
2014-01-22 14:23:56 -05:00
Shea Levy
30f7947031 Whitespace to force a build
Ugh

Signed-off-by: Shea Levy <shea@shealevy.com>
2014-01-19 15:07:35 -05:00
Shea Levy
9c1d3bfa9f Whitespace to force a rebuild
Signed-off-by: Shea Levy <shea@shealevy.com>
2014-01-17 12:15:49 -05:00
Eelco Dolstra
e8baaba044 Add a regression test for hostname / nss_myhostname
Issue #1248.
2013-11-26 18:52:34 +01:00
Domen Kožar
a623cc96e3 Merge pull request #1066 from offlinehacker/nixos/logstash/update
nixos/logstash: update and simplify to be fully compatible with new version
2013-11-08 11:44:17 -08:00
Eelco Dolstra
0d5ec076d2 Use default kernel for EFI-related stuff 2013-11-07 16:38:56 +01:00
Jaka Hudoklin
8b1ab6d912 nixos/logstash: add test 2013-11-01 17:18:57 +01:00
Shea Levy
cd9786eed2 Fold efi booting into the default livecd
Signed-off-by: Shea Levy <shea@shealevy.com>
2013-11-01 11:29:36 -04:00
Eelco Dolstra
408b8b5725 Add lots of missing option types 2013-10-30 18:47:43 +01:00
Eelco Dolstra
adc1b38b85 Add a priority level for overrides in VM tests
Now that overriding fileSystems in qemu-vm.nix works again, it's
important that the VM tests that add additional file systems use the
same override priority.  Instead of using the same magic constant
everywhere, they can now use mkVMOverride.

http://hydra.nixos.org/build/6695561
2013-10-29 13:14:30 +01:00
Eelco Dolstra
98ae32286f Fix evaluation error in the tomcat test 2013-10-29 01:26:51 +01:00
Eelco Dolstra
30a36f9a80 Remove remaining uses of mkOverrideTemplate 2013-10-28 22:45:58 +01:00
Domen Kožar
aeff0028bf munin: add test and fix a bug 2013-10-20 21:16:24 +02:00
aszlig
1fc7d6ddb2
nixos/tests: Temporarily deactivate nixpart tests.
Those tests are flapping and redundant to some degree, as two
configurations are tested in NixOps as well. So, let's deactivate them
until the 1.0 release of nixpart, which has a more general approach for
automatically partitioning NixOS installations.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
2013-10-19 23:34:20 +02:00
Eelco Dolstra
8c047d4f2c Test whether PAM resource limits work 2013-10-17 15:37:08 +02:00
Eelco Dolstra
b3debdc046 Fix test evaluation 2013-10-16 12:47:11 +02:00
Eelco Dolstra
756ca94e0c Really fix the EFI installer test
http://hydra.nixos.org/build/6497361
2013-10-16 12:16:34 +02:00
Eelco Dolstra
ee72a0c386 Disable the trac test
It's been failing since forever.
2013-10-16 11:49:10 +02:00
Eelco Dolstra
6dafee8d67 Fix runInMachine
It requires a writable /nix/store to store the build result.  Also,
wait until we've reached multi-user.target before doing the build, and
do a sync at the end to ensure all data to $out is properly written.

http://hydra.nixos.org/build/6496716
2013-10-16 11:37:38 +02:00
Shea Levy
50f4822888 Fix efi installer test
Signed-off-by: Shea Levy <shea@shealevy.com>
2013-10-14 16:02:29 -04:00
Eelco Dolstra
903c5d4df9 Test nixos-option 2013-10-13 22:36:04 +02:00
Eelco Dolstra
de7083a495 Fix the misc test
http://hydra.nixos.org/build/6480163
2013-10-13 22:17:12 +02:00
Eelco Dolstra
647b0f5f5c Update the installer tests for nixos-generate-config 2013-10-13 17:35:57 +02:00
Eelco Dolstra
5c1f8cbc70 Move all of NixOS to nixos/ in preparation of the repository merge 2013-10-10 13:28:20 +02:00