nixpkgs/nixos/modules/services
Maximilian Bosch 35b146ca31
nixos/nextcloud: fixup openssl compat change
Upon testing the change itself I realized that it doesn't build properly
because

* the `pname` of a php extension is `php-<name>`, not `<name>`.
* calling the extension `openssl-legacy` resulted in PHP trying to compile
  `ext/openssl-legacy` which broke since it doesn't exist:

      source root is php-8.1.12
      setting SOURCE_DATE_EPOCH to timestamp 1666719000 of file php-8.1.12/win32/wsyslog.c
      patching sources
      cdToExtensionRootPhase
      /nix/store/48mnkga4kh84xyiqwzx8v7iv090i7z66-stdenv-linux/setup: line 1399: cd: ext/openssl-legacy: No such file or directory

I didn't encounter that one before because I was mostly interested in
having a sane behavior for everyone not using this "feature" and the
documentation around this. My findings about the behavior with turning
openssl1.1 on/off are still valid because I tested this on `master` with
manually replacing `openssl` by `openssl_1_1` in `php-packages.nix`.

To work around the issue I had to slightly modify the extension
build-system for PHP:

* The attribute `extensionName` is now relevant to determine the output
  paths (e.g. `lib/openssl.so`). This is not a behavioral change for
  existing extensions because then `extensionName==name`.

  However when specifying `extName` in `php-packages.nix` this value is
  overridden and it is made sure that the extension called `extName` NOT
  `name` (i.e. `openssl` vs `openssl-legacy`) is built and installed.

  The `name` still has to be kept to keep the legacy openssl available
  as `php.extensions.openssl-legacy`.

Additionally I implemented a small VM test to check the behavior with
server-side encryption:

* For `stateVersion` below 22.11, OpenSSL 1.1 is used (in `basic.nix`
  it's checked that OpenSSL 3 is used). With that the "default"
  behavior of the module is checked.

* It is ensured that the PHP interpreter for Nextcloud's php-fpm
  actually loads the correct openssl extension.

* It is tested that (encrypted) files remain usable when (temporarily)
  installing OpenSSL3 (of course then they're not decryptable, but on a
  rollback that should still be possible).

Finally, a few more documentation changes:

* I also mentioned the issue in `nextcloud.xml` to make sure the issue
  is at least mentioned in the manual section about Nextcloud. Not too
  much detail here, but the relevant option `enableBrokenCiphersForSSE`
  is referenced.

* I fixed a few minor wording issues to also give the full context
  (we're talking about Nextcloud; we're talking about the PHP extension
  **only**; please check if you really need this even though it's
  enabled by default).

  This is because I felt that sometimes it might be hard to understand
  what's going on when e.g. an eval-warning appears without telling where
  exactly it comes from.
2022-11-11 14:45:46 +01:00
..
admin pgadmin4: 6.12 -> 6.13 2022-09-22 17:42:20 +02:00
amqp nixos/*: automatically convert option descriptions 2022-08-31 16:32:53 +02:00
audio nixos/navidrome: set proper SystemCallFilter 2022-10-24 22:21:59 +10:00
backup nixos/btrbk: fix ordering of subsections and refactor 2022-10-24 08:52:25 +08:00
blockchain/ethereum lighthouse: module add defaults 2022-11-07 09:15:49 -05:00
cluster Merge pull request #194759 from hercules-ci/fqdn-or-hostname 2022-11-09 13:53:57 +01:00
computing nixos/*: convert internal option descriptions to MD 2022-08-31 16:32:54 +02:00
continuous-integration nixos/jenkins-job-builder: better defaults for accessUser/accessTokenFile 2022-10-30 19:01:48 +01:00
databases nixos/influxdb2: set timezone data environment variable 2022-11-06 11:12:42 +11:00
desktops nixos/geoclue2: make system service wait on network-online 2022-11-09 16:50:18 +00:00
development nixos/*: convert straggler options to MD 2022-08-31 17:27:38 +02:00
display-managers nixos/*: automatically convert option descriptions 2022-08-31 16:32:53 +02:00
editors nixos/*: automatically convert option descriptions 2022-08-31 16:32:53 +02:00
finance nixos/*: automatically convert option descriptions 2022-08-31 16:32:53 +02:00
games nixos/*: convert straggler options to MD 2022-08-31 17:27:38 +02:00
hardware nixos/sane: mention sane-airscan in the extraBackends option 2022-11-05 16:19:04 +01:00
home-automation nixos/home-assistant: update bluetooth components 2022-11-05 13:30:17 +01:00
logging logrotate: add services.logrotate.settings example 2022-11-05 10:34:04 +09:00
mail Merge pull request #189756 from alyssais/mailman-virtualRoot 2022-11-06 12:42:48 +01:00
matrix nixos/mautrix-telegram: fix link to example config 2022-10-30 13:20:16 -04:00
misc Merge pull request #200388 from babbaj/remove-ethminer 2022-11-09 12:06:28 -03:00
monitoring Merge pull request #194759 from hercules-ci/fqdn-or-hostname 2022-11-09 13:53:57 +01:00
network-filesystems Merge pull request #197104 from Luflosi/kubo-RFC42 2022-10-27 23:48:33 +02:00
networking nixos/firefox-syncserver: fix setup failure due to duplicate key 2022-11-09 23:39:08 +01:00
printing nixos/printing: add services.printing.stateless option 2022-10-17 22:59:24 +01:00
scheduling treewide: automatically md-convert option descriptions 2022-07-30 15:16:34 +02:00
search hound, nixos/hound: deduplicate runtime deps 2022-10-23 12:50:24 +10:00
security Merge pull request #197221 from azahi/endlessh-module 2022-11-01 23:44:25 +01:00
system nixos/cloud-init: fix hostname and resolvconf configuration 2022-10-27 08:07:48 +02:00
torrent rmem_max: define merge function 2022-11-08 10:30:10 -05:00
tracing nixos/*: automatically convert option descriptions 2022-08-31 16:32:53 +02:00
ttys nixos/getty: mkdefault for etc/issue 2022-10-05 12:46:23 -04:00
video nixos/*: convert options with admonitions to MD 2022-08-31 16:36:16 +02:00
wayland nixos/*: automatically convert option descriptions 2022-08-31 16:32:53 +02:00
web-apps nixos/nextcloud: fixup openssl compat change 2022-11-11 14:45:46 +01:00
web-servers nixos/merecat: init 2022-10-31 09:24:28 +01:00
x11 nixos/lightdm: add greeters.mobile config option 2022-11-07 05:48:23 -08:00