···46464747- `renovate` was updated to v40. See the [upstream release notes](https://github.com/renovatebot/renovate/releases/tag/40.0.0) for breaking changes.
48484949+- The Postfix module has been updated and likely requires configuration changes:
5050+ - The `services.postfix.sslCert` and `sslKey` options were removed and you now need to configure
5151+ - [services.postfix.config.smtpd_tls_chain_files](#opt-services.postfix.config.smtpd_tls_chain_files) for server certificates,
5252+ - [services.postfix.config.smtp_tls_chain_files](#opt-services.postfix.config) for client certificates.
5353+4954## Other Notable Changes {#sec-release-25.11-notable-changes}
50555156<!-- To avoid merge conflicts, consider adding your item at an arbitrary place in the list instead. -->
+67-33
nixos/modules/services/mail/postfix.nix
···55 ...
66}:
77let
88+ inherit (lib)
99+ mkOption
1010+ types
1111+ ;
812913 cfg = config.services.postfix;
1014 user = cfg.user;
···4751 );
4852 mkEntry = name: value: "${escape name} =${mkVal value}";
4953 in
5050- lib.concatStringsSep "\n" (lib.mapAttrsToList mkEntry cfg.config) + "\n" + cfg.extraConfig;
5454+ lib.concatStringsSep "\n" (
5555+ lib.mapAttrsToList mkEntry (lib.filterAttrsRecursive (_: value: value != null) cfg.config)
5656+ )
5757+ + "\n"
5858+ + cfg.extraConfig;
51595260 masterCfOptions =
5361 {
···564572 };
565573566574 config = lib.mkOption {
567567- type =
568568- with lib.types;
569569- attrsOf (oneOf [
570570- bool
571571- int
572572- str
573573- (listOf str)
574574- ]);
575575+ type = lib.types.submodule {
576576+ freeformType =
577577+ with types;
578578+ attrsOf (
579579+ nullOr (oneOf [
580580+ bool
581581+ int
582582+ str
583583+ (listOf str)
584584+ ])
585585+ );
586586+ options = {
587587+ smtpd_tls_chain_files = mkOption {
588588+ type = with types; listOf path;
589589+ default = [ ];
590590+ example = [
591591+ "/var/lib/acme/mail.example.com/privkey.pem"
592592+ "/var/lib/acme/mail.example.com/fullchain.pem"
593593+ ];
594594+ description = ''
595595+ List of paths to the server private keys and certificates.
596596+597597+ ::: {.caution}
598598+ The order of items matters and a private key must always be followed by the corresponding certificate.
599599+ :::
600600+601601+ <https://www.postfix.org/postconf.5.html#smtpd_tls_chain_files>
602602+ '';
603603+ };
604604+605605+ smtpd_tls_security_level = mkOption {
606606+ type = types.enum [
607607+ "none"
608608+ "may"
609609+ "encrypt"
610610+ ];
611611+ default = if config.services.postfix.config.smtpd_tls_chain_files != [ ] then "may" else "none";
612612+ defaultText = lib.literalExpression ''
613613+ if config.services.postfix.config.smtpd_tls_chain_files != [ ] then "may" else "none"
614614+ '';
615615+ example = "may";
616616+ description = ''
617617+ The server TLS security level. Enable TLS by configuring at least `may`.
618618+619619+ <https://www.postfix.org/postconf.5.html#smtpd_tls_security_level>
620620+ '';
621621+ };
622622+ };
623623+ };
624624+575625 description = ''
576626 The main.cf configuration file as key value set.
627627+628628+ Null values will not be rendered.
577629 '';
578630 example = {
579631 mail_owner = "postfix";
···597649 description = ''
598650 File containing trusted certification authorities (CA) to verify certificates of mailservers contacted for mail delivery. This sets [smtp_tls_CAfile](https://www.postfix.org/postconf.5.html#smtp_tls_CAfile). Defaults to system trusted certificates (see `security.pki.*` options).
599651 '';
600600- };
601601-602602- sslCert = lib.mkOption {
603603- type = lib.types.str;
604604- default = "";
605605- description = "SSL certificate to use.";
606606- };
607607-608608- sslKey = lib.mkOption {
609609- type = lib.types.str;
610610- default = "";
611611- description = "SSL key to use.";
612652 };
613653614654 recipientDelimiter = lib.mkOption {
···9741014 // lib.optionalAttrs (cfg.tlsTrustedAuthorities != "") {
9751015 smtp_tls_CAfile = cfg.tlsTrustedAuthorities;
9761016 smtp_tls_security_level = lib.mkDefault "may";
977977- }
978978- // lib.optionalAttrs (cfg.sslCert != "") {
979979- smtp_tls_cert_file = cfg.sslCert;
980980- smtp_tls_key_file = cfg.sslKey;
981981-982982- smtp_tls_security_level = lib.mkDefault "may";
983983-984984- smtpd_tls_cert_file = cfg.sslCert;
985985- smtpd_tls_key_file = cfg.sslKey;
986986-987987- smtpd_tls_security_level = lib.mkDefault "may";
988988-9891017 };
99010189911019 services.postfix.masterConfig =
···11491177 imports = [
11501178 (lib.mkRemovedOptionModule [ "services" "postfix" "sslCACert" ]
11511179 "services.postfix.sslCACert was replaced by services.postfix.tlsTrustedAuthorities. In case you intend that your server should validate requested client certificates use services.postfix.extraConfig."
11801180+ )
11811181+ (lib.mkRemovedOptionModule [ "services" "postfix" "sslCert" ]
11821182+ "services.postfix.sslCert was removed. Use services.postfix.config.smtpd_tls_chain_files for the server certificate, or services.postfix.config.smtp_tls_chain_files for the client certificate."
11831183+ )
11841184+ (lib.mkRemovedOptionModule [ "services" "postfix" "sslKey" ]
11851185+ "services.postfix.sslKey was removed. Use services.postfix.config.smtpd_tls_chain_files for server private key, or services.postfix.config.smtp_tls_chain_files for the client private key."
11521186 )
1153118711541188 (lib.mkChangedOptionModule