Skip to content

Commit

Permalink
Explain the usage of the -settings-id parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
mneumann committed Nov 30, 2020
1 parent 1054fe6 commit 1cfe989
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,5 +62,34 @@ filter "rspamd" proc-exec "filter-rspamd -url http://example.org:11333"
listen on all filter "rspamd"
```

Optionally a `-settings-id` parameter can be used to select a specific rspamd
setting. One usecase is for example to apply different rspamd rules to incoming
and outgoing emails:

```
filter "rspamd-incoming" proc-exec "filter-rspamd"
filter "rspamd-outgoing" proc-exec "filter-rspamd -settings-id outgoing"
listen on all filter "rspamd-incoming"
listen on all port submission filter "rspamd-outgoing"
```

And in `rspamd/local.d/settings.conf`:

```
outgoing {
id = "outgoing";
apply {
enable_groups = ["dkim"];
actions {
reject = 100.0;
greylist = 100.0;
"add header" = 100.0;
}
}
}
```

Every email passed through the `rspamd-outgoing` filter will use the rspamd `outgoing` rule instead of the default rule.

Any configuration with regard to thresholds or enabled modules must be done in rspamd itself.

0 comments on commit 1cfe989

Please sign in to comment.