Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update rspamd #40434

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion lib/modules.nix
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,17 @@ rec {
result of the change function
*/
mkChangedOptionModule = from: to: changeFn:
mkMergedOptionModule [ from ] to changeFn;
{ config, options, ... }:
{ options = setAttrByPath from (mkOption {
visible = false;
});
config =
let opt = getAttrFromPath from options; in {
warnings =
optional opt.isDefined
"The option `${showOption from}' defined in ${showFiles opt.files} has been changed to `${showOption to}' that has a different type. Please read `${showOption to}' documentation and update your configuration accordingly.";
} // setAttrByPath to (mkIf opt.isDefined (changeFn config));
};

/* Like ‘mkRenamedOptionModule’, but doesn't show a warning. */
mkAliasOptionModule = from: to: doRename {
Expand Down
8 changes: 8 additions & 0 deletions nixos/doc/manual/release-notes/rl-1809.xml
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,14 @@ $ nix-instantiate -E '(import <nixpkgsunstable> {}).gitFull'
<literal>networking.networkmanager.dns</literal> instead.
</para>
</listitem>
<listitem>
<para>
<literal>services.rmilter</literal> has been deprecated and corresponding package removed.
rspamd now listens on a UNIX socket by default. Use <literal>services.rspamd.postfix.enable</literal>
instead of <literal>services.rmilter.postfix.enable</literal> for quick Postfix integration.
</para>
</listitem>

</itemizedlist>
</section>
</section>
1 change: 0 additions & 1 deletion nixos/modules/module-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,6 @@
./services/mail/postgrey.nix
./services/mail/spamassassin.nix
./services/mail/rspamd.nix
./services/mail/rmilter.nix
./services/mail/nullmailer.nix
./services/misc/airsonic.nix
./services/misc/apache-kafka.nix
Expand Down
6 changes: 3 additions & 3 deletions nixos/modules/rename.nix
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,6 @@ with lib;
(mkRemovedOptionModule [ "security" "setuidOwners" ] "Use security.wrappers instead")
(mkRemovedOptionModule [ "security" "setuidPrograms" ] "Use security.wrappers instead")

(mkRemovedOptionModule [ "services" "rmilter" "bindInetSockets" ] "Use services.rmilter.bindSocket.* instead")
(mkRemovedOptionModule [ "services" "rmilter" "bindUnixSockets" ] "Use services.rmilter.bindSocket.* instead")

# Xsession script
(mkRenamedOptionModule [ "services" "xserver" "displayManager" "job" "logsXsession" ] [ "services" "xserver" "displayManager" "job" "logToFile" ])
(mkRenamedOptionModule [ "services" "xserver" "displayManager" "logToJournal" ] [ "services" "xserver" "displayManager" "job" "logToJournal" ])
Expand Down Expand Up @@ -250,6 +247,9 @@ with lib;
(mkRenamedOptionModule [ "programs" "info" "enable" ] [ "documentation" "info" "enable" ])
(mkRenamedOptionModule [ "programs" "man" "enable" ] [ "documentation" "man" "enable" ])

# rmilter
(mkRemovedOptionModule [ "services" "rmilter" ] "Use services.rspamd directly instead")

] ++ (flip map [ "blackboxExporter" "collectdExporter" "fritzboxExporter"
"jsonExporter" "minioExporter" "nginxExporter" "nodeExporter"
"snmpExporter" "unifiExporter" "varnishExporter" ]
Expand Down
249 changes: 0 additions & 249 deletions nixos/modules/services/mail/rmilter.nix

This file was deleted.

Loading