Commit graph

2333 commits

Author SHA1 Message Date
Maximilian Bosch 5e124e5abd
nixos/tests: fix inclusion of hydra test 2020-04-16 02:17:25 +02:00
Florian Klink 28ef43824b nixosTests.flannel: port to python, unbreak
For reasons yet unknown, the vxlan backend doesn't work (at least inside
the qemu networking), so this is moved to the udp backend.

Note changing the backend apparently also changes the interface name,
it's now `flannel0`, not `flannel.1`

fixes #74941
2020-04-14 23:56:42 +02:00
Michele Guerini Rocco 86d71ddbed
Merge pull request #85170 from flokli/networking-virtual
nixos/networking: fix setting MAC Address and MTU in networkd, fix tests
2020-04-14 14:20:49 +02:00
worldofpeace 57b862bb53
Merge pull request #85125 from iblech/patch-iodine-test
iodine: improve test in view of #58806
2020-04-14 08:03:23 -04:00
Florian Klink d1edd8b2f6 nixosTests.networking: test setting MTU and MAC Address
Both the scripted and networkd backend now support setting MTU and MAC
Address, so do this in a test to ensure it doesn't break.
2020-04-13 22:03:35 +02:00
Florian Klink 5150378c2f nixosTests.networking.virtual: fix with networkd
We only need to wait for network.target to get up, and the
network-addresses-${interfaceName} units are scripted networking only.
2020-04-13 22:03:35 +02:00
Florian Klink 1e1945319c nixosTests.networking: make routing table comparison more reliable
This was whitespace-sensitive, kept fighting with my editor and broke
the tests easily. To fix this, let python convert the output to
individual lines, and strip whitespace from them before comparing.
2020-04-13 22:03:35 +02:00
Ingo Blechschmidt f379e74f1e iodine: improve test in view of #58806 2020-04-13 06:22:27 +02:00
Ioannis Koutras 9360e3723d nixos/traefik: add test 2020-04-12 22:50:36 +02:00
Graham Christensen 35d8514a91
Merge pull request #81848 from grahamc/nested-specialisation
specialisation: replace nesting with named configurations
2020-04-12 08:56:11 -04:00
Graham Christensen ec2d28e323
specialisation: replace nesting with named configurations
Co-authored-by: worldofpeace <worldofpeace@protonmail.ch>
2020-04-12 08:12:50 -04:00
Maximilian Bosch c9504b0b68
Merge pull request #84940 from symphorien/rouncube-spell
roundcube: use pspell for spellchecking
2020-04-11 14:33:43 +02:00
Michael Reilly 84cf00f980
treewide: Per RFC45, remove all unquoted URLs 2020-04-10 17:54:53 +01:00
Symphorien Gibol 9e417bc9e3 roundcube: use pspell for spellchecking
By default, upstream enables a third party service in the cloud:
https://github.com/roundcube/roundcubemail/blob/1.4.3/config/defaults.inc.php#L790-L798
2020-04-10 12:00:00 +00:00
Maximilian Bosch e8a4b9fe9b
Merge pull request #84501 from Ma27/bump-hydra
hydra: 2020-03-24 -> 2020-04-07
2020-04-08 20:08:29 +02:00
Jörg Thalheim 0b5d6d9e39
Merge pull request #84556 from Mic92/runtime-shell
treewide: use runtimeShell in nixos/
2020-04-08 16:34:55 +01:00
Michael Bishop 8b7e843dab
nixos: kafka test: fix building for other arches 2020-04-07 12:50:58 -03:00
Maximilian Bosch 0f5c38feed
hydra: 2020-03-24 -> 2020-04-07
Also removed `pkgs.hydra-flakes` since flake-support has been merged
into master[1]. Because of that, `pkgs.hydra-unstable` is now compiled
against `pkgs.nixFlakes` and currently requires a patch since Hydra's
master doesn't compile[2] atm.

[1] https://github.com/NixOS/hydra/pull/730
[2] https://github.com/NixOS/hydra/pull/732
2020-04-07 14:11:12 +02:00
Jörg Thalheim cf3328e7e3
treewide: use runtimeShell in nixos/
This is needed for cross-compilation.
2020-04-07 07:26:47 +01:00
Sarah Brofeldt b256b2253c
Merge pull request #83749 from srhb/ceph-14.2.8
ceph: 14.2.7 -> 14.2.8
2020-04-06 07:44:02 +02:00
Elis Hirwing 3b6539896b
Merge pull request #83896 from etu/slim-down-default-php-v3
PHP: Make the default package more sane [v3]
2020-04-05 20:00:03 +02:00
Elis Hirwing 0dc95728ba
nixos/php: Move the pcre tests to the php test attribute 2020-04-05 16:44:59 +02:00
Elis Hirwing 29e1f0d169
nixos/php: Add tests for phpfpm
This test checks that we evaluate PHP properly and that certain
extensions are actually loaded.
2020-04-05 16:44:54 +02:00
Frederik Rietdijk 92124ed660 Merge master into staging-next 2020-04-03 21:54:40 +02:00
Sarah Brofeldt 6ccd347e46 nixos/tests/ceph: Fix pg number to power of 2 2020-04-02 21:11:45 +02:00
Léo Gaspard a3ee24b2ff
Merge pull request #83894 from symphorien/unbreak-os-prober-test
Unbreak os prober test
2020-03-31 22:17:27 +02:00
Jan Tojnar 3e0f4e202f
Merge branch 'master' into staging-next 2020-03-31 21:32:15 +02:00
Florian Klink a3d67bfd42
Merge pull request #83765 from Izorkin/mariadb-test
nixos/mysql: add test mariadb with tokudb plugin
2020-03-31 20:23:45 +02:00
Izorkin 6af90a3df8 nixos/mysql: add test mariadb with rocksdb plugin 2020-03-31 14:46:04 +03:00
Marek Mahut af75bb17b9 nixos/tests: add magic-wormhole-mailbox-server 2020-03-30 16:15:15 +02:00
Izorkin ba55f84b5d nixos/mysql: add test mariadb with tokudb plugin 2020-03-30 13:42:51 +03:00
Florian Klink f4f8921f97
nixos/gerrit: stop setting jvmPackage (#83696)
jdk12_headless disappeared in d00559ebb8,
and just using the default in the VM test should be fine IMHO.
2020-03-29 18:50:19 +00:00
Symphorien Gibol 6a2f64a542 nixos/tests/os-prober.nix: fix out of memory 2020-03-29 15:30:33 +02:00
Maximilian Bosch 2c133fbb4b
nixos/tests/mongodb: also test mongodb-3_4 2020-03-29 01:09:53 +01:00
Jan Tojnar fa4e1bbe07
Merge branch 'master' into staging-next
Fix eval of nixos/nginx
2020-03-29 00:35:29 +01:00
Graham Christensen 4d226bad77
Merge pull request #83600 from Ma27/hydra-two-stage-deploy
hydra: 2020-02-06 -> 2020-03-{24,27}
2020-03-28 19:18:10 -04:00
Maximilian Bosch bd5324c4fc
hydra: 2020-02-06 -> 2020-03-{24,27}
Upgrades Hydra to the latest master/flake branch. To perform this
upgrade, it's needed to do a non-trivial db-migration which provides a
massive performance-improvement[1].

The basic ideas behind multi-step upgrades of services between NixOS versions
have been gathered already[2]. For further context it's recommended to
read this first.

Basically, the following steps are needed:

* Upgrade to a non-breaking version of Hydra with the db-changes
  (columns are still nullable here). If `system.stateVersion` is set to
  something older than 20.03, the package will be selected
  automatically, otherwise `pkgs.hydra-migration` needs to be used.

* Run `hydra-backfill-ids` on the server.

* Deploy either `pkgs.hydra-unstable` (for Hydra master) or
  `pkgs.hydra-flakes` (for flakes-support) to activate the optimization.

The steps are also documented in the release-notes and in the module
using `warnings`.

`pkgs.hydra` has been removed as latest Hydra doesn't compile with
`pkgs.nixStable` and to ensure a graceful migration using the newly
introduced packages.

To verify the approach, a simple vm-test has been added which verifies
the migration steps.

[1] https://github.com/NixOS/hydra/pull/711
[2] https://github.com/NixOS/nixpkgs/pull/82353#issuecomment-598269471
2020-03-28 23:33:25 +01:00
worldofpeace b1bffdf67f
Merge pull request #83425 from xfix/mark-hibernation-test-as-broken-on-aarch
nixos/tests/hibernate: disable for platforms other than x86_64
2020-03-28 18:22:08 -04:00
Frederik Rietdijk a36be028f5 Merge staging-next into staging 2020-03-28 21:15:15 +01:00
Maximilian Bosch 63e81053b0
Merge pull request #74504 from xwvvvvwx/wg-quick-tests
tests/wireguard: init wg-quick
2020-03-28 16:26:43 +01:00
Konrad Borowski d85fb28414 nixos/tests/hibernate: disable for platforms other than x86_64
Due to 9pnet_virtio bugs, /nix is no longer available after
hibernation. It happens to work on x86_64, but not on other
platforms.
2020-03-28 09:31:36 +01:00
Yegor Timoshenko 5626cb9486
Merge pull request #82603 from emilazy/nixos-initrd-openssh
nixos/initrd-ssh: switch from Dropbear to OpenSSH
2020-03-28 09:22:02 +01:00
Marek Mahut 42d03aabbd
Merge pull request #83309 from mmahut/quorum
nixos/quorum: init
2020-03-28 09:04:12 +01:00
aszlig e1d63ada02
nginx: Fix ETag patch to ignore realpath(3) error
While our ETag patch works pretty fine if it comes to serving data off
store paths, it unfortunately broke something that might be a bit more
common, namely when using regexes to extract path components of
location directives for example.

Recently, @devhell has reported a bug with a nginx location directive
like this:

  location ~^/\~([a-z0-9_]+)(/.*)?$" {
    alias /home/$1/public_html$2;
  }

While this might look harmless at first glance, it does however cause
issues with our ETag patch. The alias directive gets broken up by nginx
like this:

  *2 http script copy: "/home/"
  *2 http script capture: "foo"
  *2 http script copy: "/public_html/"
  *2 http script capture: "bar.txt"

In our patch however, we use realpath(3) to get the canonicalised path
from ngx_http_core_loc_conf_s.root, which returns the *configured* value
from the root or alias directive. So in the example above, realpath(3)
boils down to the following syscalls:

  lstat("/home", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
  lstat("/home/$1", 0x7ffd08da6f60) = -1 ENOENT (No such file or directory)

During my review[1] of the initial patch, I didn't actually notice that
what we're doing here is returning NGX_ERROR if the realpath(3) call
fails, which in turn causes an HTTP 500 error.

Since our patch actually made the canonicalisation (and thus additional
syscalls) necessary, we really shouldn't introduce an additional error
so let's - at least for now - silently skip return value if realpath(3)
has failed.

However since we're using the unaltered root from the config we have
another issue, consider this root:

  /nix/store/...-abcde/$1

Calling realpath(3) on this path will fail (except if there's a file
called "$1" of course), so even this fix is not enough because it
results in the ETag not being set to the store path hash.

While this is very ugly and we should fix this very soon, it's not as
serious as getting HTTP 500 errors for serving static files.

I added a small NixOS VM test, which uses the example above as a
regression test.

It seems that my memory is failing these days, since apparently I *knew*
about this issue since digging for existing issues in nixpkgs, I found
this similar pull request which I even reviewed:

https://github.com/NixOS/nixpkgs/pull/66532

However, since the comments weren't addressed and the author hasn't
responded to the pull request, I decided to keep this very commit and do
a follow-up pull request.

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

Signed-off-by: aszlig <aszlig@nix.build>
Reported-by: @devhell
Acked-by: @7c6f434c
Acked-by: @yorickvP
Merges: https://github.com/NixOS/nixpkgs/pull/80671
Fixes: https://github.com/NixOS/nixpkgs/pull/66532
2020-03-28 02:57:21 +01:00
Marek Mahut 870a6e262d nixos/quorum: init 2020-03-27 19:31:01 +01:00
Maximilian Bosch 2934f04641
nixos/tests/mongodb: rewrite with python
perl-based VM tests are deprecated.
2020-03-26 14:02:49 +01:00
Nathan Smyth 44641ed00b
nixos/tests/mongodb: test against mongodb versions 3.4, 3.6, 4.0
Now has tests for 3.4, 3.6, 4.0. Has some duplication, but it appears to
work on my machine.
2020-03-26 14:02:49 +01:00
zimbatm d8f0c5407e
Merge pull request #82929 from zimbatm/nixos-gerrit
nixos gerrit module
2020-03-26 12:47:15 +01:00
zimbatm d37a0dca13
nixos: add gerrit module
Co-authored-by: edef <edef@edef.eu>
Co-authored-by: Florian Klink <flokli@flokli.de>
2020-03-26 09:28:42 +01:00
Michael Weiss 216a7e7a98
nixosTests.installer: Don't wait for the nixos-manual service
The nixos-manual service was removed in #83199 but we missed the check
in this test which prevents the "tested" job from succeeding [0][1].

[0]: https://hydra.nixos.org/build/115472896
[1]: https://hydra.nixos.org/build/115472896/nixlog/94/tail
2020-03-26 01:21:34 +01:00