nixpkgs/nixos/modules/services/mail
talyz 2ba7926959
php.buildEnv: Provide a list of currently enabled extensions
Rework withExtensions / buildEnv to handle currently enabled
extensions better and make them compatible with override. They now
accept a function with the named arguments enabled and all, where
enabled is a list of currently enabled extensions and all is the set
of all extensions. This gives us several nice properties:

 - You always get the right version of the list of currently enabled
   extensions

 - Invocations chain

 - It works well with overridden PHP packages - you always get the
   correct versions of extensions

As a contrived example of what's possible, you can add ImageMagick,
then override the version and disable fpm, then disable cgi, and
lastly remove the zip extension like this:

{ pkgs ? (import <nixpkgs>) {} }:
with pkgs;

let
  phpWithImagick = php74.withExtensions ({ all, enabled }: enabled ++ [ all.imagick ]);

  phpWithImagickWithoutFpm743 = phpWithImagick.override {
    version = "7.4.3";
    sha256 = "wVF7pJV4+y3MZMc6Ptx21PxQfEp6xjmYFYTMfTtMbRQ=";
    fpmSupport = false;
  };

  phpWithImagickWithoutFpmZip743 = phpWithImagickWithoutFpm743.withExtensions (
    { enabled, all }:
      lib.filter (e: e != all.zip) enabled);

  phpWithImagickWithoutFpmZipCgi743 = phpWithImagickWithoutFpmZip743.override {
    cgiSupport = false;
  };
in
  phpWithImagickWithoutFpmZipCgi743
2020-04-26 16:43:05 +02:00
..
clamsmtp.nix clamsmtp module: add self as maintainer 2018-10-31 01:05:49 +09:00
davmail.nix nixos/modules: Replace all nested types.either's with types.oneOf's 2019-08-08 23:35:52 +02:00
dkimproxy-out.nix dkimproxy-out module: add self as maintainer 2018-10-31 01:06:04 +09:00
dovecot.nix dovecot: add missing descriptions 2020-01-28 12:00:00 +00:00
dspam.nix treewide: use attrs instead of list for types.loaOf options 2020-01-06 10:39:18 -05:00
exim.nix treewide: use attrs instead of list for types.loaOf options 2020-01-06 10:39:18 -05:00
freepops.nix
mail.nix [bot] nixos/*: remove unused arguments in lambdas 2018-07-20 20:56:59 +00:00
mailcatcher.nix nixos/mailcatcher: add http.path option 2019-11-12 10:11:24 -05:00
mailhog.nix treewide: Switch to system users 2019-10-12 22:25:28 +02:00
mailman.nix services.mailman: RemainAfterExit so settings take effect properly 2020-03-02 02:25:20 +00:00
mlmmj.nix treewide: use attrs instead of list for types.loaOf options 2020-01-06 10:39:18 -05:00
nullmailer.nix treewide: use attrs instead of list for types.loaOf options 2020-01-06 10:39:18 -05:00
offlineimap.nix cleanup redundant text in modules utilizing mkEnableOption 2019-04-20 14:44:02 +02:00
opendkim.nix tree-wide: fix errors and warning related to loaOf deprecation 2020-01-07 06:23:28 +01:00
opensmtpd.nix nixos/opensmtpd: refactor to use tmpfiles to set up spool directories 2019-11-08 15:05:18 +01:00
pfix-srsd.nix treewide: remove redundant quotes 2019-08-26 21:40:19 +00:00
postfix.nix tree-wide: fix more warning related to loaOf deprecation 2020-01-11 08:09:56 +01:00
postgrey.nix nixos/treewide: Move rename.nix imports to their respective modules 2019-12-10 02:51:19 +01:00
postsrsd.nix treewide: use attrs instead of list for types.loaOf options 2020-01-06 10:39:18 -05:00
roundcube.nix php.buildEnv: Provide a list of currently enabled extensions 2020-04-26 16:43:05 +02:00
rspamd.nix treewide: use attrs instead of list for types.loaOf options 2020-01-06 10:39:18 -05:00
rss2email.nix nixos/rss2email: globally install rss2email 2020-04-18 14:16:00 +00:00
spamassassin.nix treewide: add bool type to enable options, or make use of mkEnableOption 2020-04-21 08:55:36 +02:00
sympa.nix nixos/sympa: fix outgoing messaging 2020-03-24 02:35:39 +01:00