Commit Graph

2399 Commits

Author SHA1 Message Date
Florian Klink
e148a72377
Merge pull request #86067 from NinjaTrappeur/nin-sane-prosody-defaults
nixos/prosody: make module defaults comply with XEP-0423
2020-05-01 20:07:13 +02:00
Andreas Rammhold
47529bcf7f
nixos/tests: add systemd-networkd-ipv6-prefix-delegation
This is a follow-up to the PR #82026 that contains the promised tests.

In this test I am testing if we can properly propagate prefixes received
via DHCPv6 PD with the networkd options in our module system.

The comments in the test should be sufficient to follow the idea and
what is going on.
2020-05-01 16:55:53 +02:00
Aaron Andersen
5445b8d8d0
Merge pull request #83436 from mmilata/mediawiki-default-extensions
nixos/mediawiki: allow using default extensions
2020-04-30 21:03:15 -04:00
Félix Baylac-Jacqué
8aea528872
nixos/prosody: make defaults comply with XEP-0423
Setting up a XMPP chat server is a pretty deep rabbit whole to jump in
when you're not familiar with this whole universe. Your experience
with this environment will greatly depends on whether or not your
server implements the right set of XEPs.

To tackle this problem, the XMPP community came with the idea of
creating a meta-XEP in charge of listing the desirable XEPs to comply
with. This meta-XMP is issued every year under an new XEP number. The
2020 one being XEP-0423[1].

This prosody nixos module refactoring makes complying with XEP-0423
easier. All the necessary extensions are enabled by default. For some
extensions (MUC and HTTP_UPLOAD), we need some input from the user and
cannot provide a sensible default nixpkgs-wide. For those, we guide
the user using a couple of assertions explaining the remaining manual
steps to perform.

We took advantage of this substential refactoring to refresh the
associated nixos test.

Changelog:
- Update the prosody package to provide the necessary community
  modules in order to comply with XEP-0423. This is a tradeoff, as
  depending on their configuration, the user might end up not using them
  and wasting some disk space. That being said, adding those will
  allow the XEP-0423 users, which I expect to be the majority of
  users, to leverage a bit more the binary cache.
- Add a muc submodule populated with the prosody muc defaults.
- Add a http_upload submodule in charge of setting up a basic http
  server handling the user uploads. This submodule is in is
  spinning up an HTTP(s) server in charge of receiving and serving the
  user's attachments.
- Advertise both the MUCs and the http_upload endpoints using mod disco.
- Use the slixmpp library in place of the now defunct sleekxmpp for
  the prosody NixOS test.
- Update the nixos test to setup and test the MUC and http upload
  features.
- Add a couple of assertions triggered if the setup is not xep-0423
  compliant.

[1] https://xmpp.org/extensions/xep-0423.html
2020-04-30 20:39:54 +02:00
Elis Hirwing
3e10bd8762
nixosTests.php: Add maintainer team as maintainers 2020-04-29 20:17:08 +02:00
Elis Hirwing
410c38f317
Revert "PHP maintainer team" 2020-04-29 19:56:37 +02:00
Elis Hirwing
3b21abb3d3
Merge pull request #85575 from etu/php-maintainer-team
PHP maintainer team
2020-04-29 19:56:03 +02:00
Bas van Dijk
e26ec76d0d
Merge pull request #86321 from basvandijk/fix-elk-test
nixos/tests/elk.nix: fix issue in the elasticsearch-curator
2020-04-29 17:06:57 +02:00
Bas van Dijk
dcb01353b3 nixos/tests/elk.nix: fix issue in the elasticsearch-curator
The elasticsearch-curator was not deleting indices because the indices
had ILM policies associated with them. This is now fixed by
configuring the elasticsearch-curator with `allow_ilm_indices: true`.

Also see: https://github.com/elastic/curator/issues/1490
2020-04-29 15:23:50 +02:00
Florian Klink
21da5c4f6f nixos/oslogin: put mockuser and mockadmin in constants, rename
This allows us to change them easily without search/replacing.
Afterwards, we rename them to look a bit more like they are on GCP.
2020-04-29 14:36:35 +02:00
Florian Klink
f38e45c2e0 nixos/google-oslogin: improve mock server
some slightly better error handling for nonexistent users, less parsing
of URLs and query strings by hand.
2020-04-29 14:36:35 +02:00
worldofpeace
10bf212b4f
Merge pull request #85589 from emilazy/add-acme-maintainers-team
Add ACME maintainers team
2020-04-28 18:38:12 -04:00
Jacek Galowicz
002b553b14
Merge pull request #85781 from blitz/spike-test
Add spike integration test to nixosTests
2020-04-25 15:50:38 +02:00
worldofpeace
ee5cba24c3
Revert "ibus: fix dconf db installation" 2020-04-24 18:22:59 -04:00
worldofpeace
78a9359b2a
Merge pull request #85892 from symphorien/ibus-db
ibus: fix dconf db installation
2020-04-24 15:49:01 -04:00
Symphorien Gibol
5b7ffe6140 nixos/tests/ibus: fix test 2020-04-24 12:00:00 +00:00
adisbladis
67a61fbd34
nixos/podman: Add rootless containers to test 2020-04-24 10:50:17 +01:00
Benjamin Staffin
f09b8be73d installer test: Fix grub extraConfig syntax
It looks like `terminal_output.serial` is incorrect, according to the
grub documentation:

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

Related PR: #79406
2020-04-22 20:30:19 -04:00
Florian Klink
32516e4fee
Merge pull request #80103 from tfc/port-systemd-confinement-test
nixosTests.systemd-confinement: Port to Python
2020-04-23 01:00:51 +02:00
Julian Stecklina
a33ce7e4fb spike: add test to nixosTests 2020-04-22 14:45:12 +02:00
Jacek Galowicz
0b1bef70a9 nixosTests.redmine: Port to python 2020-04-22 08:36:27 +02:00
Elis Hirwing
9be2cbf27b
nixosTests.php: Add maintainer team as maintainers 2020-04-22 06:48:06 +02:00
Jan Tojnar
b231ac2101
Merge pull request #85402 from jtojnar/httpd-php 2020-04-22 04:23:24 +02:00
adisbladis
2d91da909e
Merge pull request #85604 from adisbladis/podman-module
nixos/virtualisation.podman: Init module
2020-04-21 23:48:48 +02:00
Tom Fitzhenry
0a49d329cb systemd-networkd: add DHCPServer test 2020-04-22 00:12:00 +10:00
adisbladis
f0a92ef1d9
nixos/podman: Add maintainer team & add myself to podman team 2020-04-21 10:03:22 +01:00
adisbladis
b512a788a4
nixos/virtualisation.podman: Init module 2020-04-21 10:03:18 +01:00
Marek Mahut
60100a7c92
Merge pull request #83769 from dadada/nixos/dokuwiki-multi-server
nixos/dokuwiki: add support for multi-site, additional plugins and templates
2020-04-20 19:39:48 +02:00
adisbladis
ab37d7e7ea
nixos-containers: Add support for custom nixpkgs argument 2020-04-20 07:33:46 +01:00
Emily
bfffee9364 nixos/tests/acme: set maintainers to acme team 2020-04-20 01:39:31 +01:00
Florian Klink
ab0da25762
Merge pull request #85503 from emilazy/acme-test-cleanups
ACME test cleanups
2020-04-19 23:57:03 +02:00
Florian Klink
a88d17bc69
Merge pull request #83301 from evils/tuptime
Tuptime: Init Package, Module and Test
2020-04-19 23:38:53 +02:00
worldofpeace
f882896cc8
Merge pull request #73934 from flokli/nixos-test-port-cockroachdb
nixosTests.cockroachdb: port to python
2020-04-19 16:30:45 -04:00
Yegor Timoshenko
6f1165a0cb
Merge pull request #84522 from emilazy/add-linux-hardened-patches
linux_*_hardened: use linux-hardened patch set
2020-04-19 20:01:35 +03:00
dadada
2d86cca35e
nixos/dokuwiki: change default of aclFile and usersFile
`aclFile` and `usersFile` will be set to a default value if `aclUse` is
specified and aclFile is not overriden by `acl`.
2020-04-18 23:37:19 +02:00
dadada
af6a7a0486
nixos/dokuwiki: add plugins and templates options
Adds support for additional plugins and templates similarly to how
wordpress.nix does it.

Plugins and templates need to be packaged as in the example.
2020-04-18 23:37:18 +02:00
dadada
dc7ed06615
nixos/dokuwiki: add <name?> option
Enables multi-site configurations.

This break compatibility with prior configurations that expect options
for a single dokuwiki instance in `services.dokuwiki`.
2020-04-18 23:37:18 +02:00
Vladimír Čunát
e233a9d4dd
Merge #84442: staging-next branch 2020-04-18 23:11:00 +02:00
Jan Tojnar
09c4736405
Merge pull request #83755 from jtojnar/jcat-0.1 2020-04-18 20:38:24 +02:00
Vladimír Čunát
d96487b9ca
Merge branch 'master' into staging-next
Hydra nixpkgs: ?compare=1582510
2020-04-18 07:42:26 +02:00
Emily
21f183a3fe nixos/tests/common/acme: don't set nameservers for client
The resolver is mainly useful for the ACME server, and acme.nix uses its
own DNS server to test DNS-01 challenges.
2020-04-18 05:15:47 +01:00
Emily
e6d5e83cf1 nixos/tests/common/acme: enable Pebble strict mode
This lets us get early warning about any bugs or backwards-compatibility
hazards in lego.

Pebble will default to this in the future, but doesn't currently;
see https://github.com/letsencrypt/pebble/blob/v2.3.0/README.md#strict-mode.
2020-04-18 05:15:47 +01:00
Emily
695fd78ac4 nixos/tests/acme: use CAP_NET_BIND_SERVICE 2020-04-18 05:15:47 +01:00
Emily
d0f04c1623 nixos/tests/acme: use *.test domains
Shimming out the Let's Encrypt domain name to reuse client configuration
doesn't work properly (Pebble uses different endpoint URL formats), is
recommended against by upstream,[1] and is unnecessary now that the ACME
module supports specifying an ACME server. This commit changes the tests
to use the domain name acme.test instead, and renames the letsencrypt
node to acme to reflect that it has nothing to do with the ACME server
that Let's Encrypt runs. The imports are renamed for clarity:

* nixos/tests/common/{letsencrypt => acme}/{common.nix => client}
* nixos/tests/common/{letsencrypt => acme}/{default.nix => server}

The test's other domain names are also adjusted to use *.test for
consistency (and to avoid misuse of non-reserved domain names such
as standalone.com).

[1] https://github.com/letsencrypt/pebble/issues/283#issuecomment-545123242

Co-authored-by: Yegor Timoshenko <yegortimoshenko@riseup.net>
2020-04-18 05:15:47 +01:00
Emily
352e30df8a nixos/tests/acme: don't restrict to x86_64
This was added in aade4e577bbb27f044217c51a006ab6ba544ebb5, but the
implementation of the ACME module has been entirely rewritten since
then, and the test seems to run fine on AArch64.
2020-04-18 05:15:47 +01:00
Milan Pässler
16a4332d60 nixos/deluge: support 2.x 2020-04-18 02:00:04 +02:00
Emily
fe031d07f8 nixos/tests/hardened: add latestKernel argument 2020-04-17 16:13:39 +01:00
Emily
ad9bfe2254 nixos/hardened: enable user namespaces for root
linux-hardened sets kernel.unprivileged_userns_clone=0 by default; see
anthraxx/linux-hardened@104f44058f.

This allows the Nix sandbox to function while reducing the attack
surface posed by user namespaces, which allow unprivileged code to
exercise lots of root-only code paths and have lead to privilege
escalation vulnerabilities in the past.

We can safely leave user namespaces on for privileged users, as root
already has root privileges, but if you're not running builds on your
machine and really want to minimize the kernel attack surface then you
can set security.allowUserNamespaces to false.

Note that Chrome's sandbox requires either unprivileged CLONE_NEWUSER or
setuid, and Firefox's silently reduces the security level if it isn't
allowed (see about:support), so desktop users may want to set:

    boot.kernel.sysctl."kernel.unprivileged_userns_clone" = true;
2020-04-17 16:13:39 +01:00
Euan Kemp
bc138f407f
nixos/k3s: add initial k3s service
* nixos/k3s: simplify config expression

* nixos/k3s: add config assertions and trim unneeded bits

* nixos/k3s: add a test that k3s works; minor module improvements

This is a single-node test. Eventually we should also have a multi-node
test to verify the agent bit works, but that one's more involved.

* nixos/k3s: add option description

* nixos/k3s: add defaults for token/serveraddr

Now that the assertion enforces their presence, we dont' need to use the typesystem for it.

* nixos/k3s: remove unneeded sudo in test

* nixos/k3s: add to test list
2020-04-17 16:39:54 +02:00
Jan Tojnar
23a6903bb7
nixosTests.php.fpm: Clean up to match httpd test 2020-04-17 14:41:20 +02:00