stalwart-mail: Fix spam-filter missing from /etc - #422909
Conversation
|
FYI: @diogotcorreia I've seen you've adjusted the spam-filter topic in #412054. I can't pin-point the exact commit, but stalwart isn't shipping the rules through the Rust build any longer. (CC also @provokateurin) |
There was a problem hiding this comment.
not sure whether this is advisable, I don't know how stalwart is downloading the https:// URLs inside the file itself.
There was a problem hiding this comment.
I've asked a question in the discussion channel.
There was a problem hiding this comment.
This is already disabled by default, so explicitly setting it shouldn't make a difference. From https://stalw.art/docs/spamfilter/settings/general/#automatic-updates :
Stalwart can be configured to automatically update the spam-filter rules on startup. This feature is disabled by default and can be enabled by setting the spam-filter.auto-update key to true.
As for downloading the https:// URLs inside, I believe stalwart downloads them anyway. That setting seems to only affect this whether rules are reloaded on startup or not: https://github.com/stalwartlabs/stalwart/blob/b2f05254232a16873f260c527f327b9d3623b7f2/crates/common/src/manager/boot.rs#L413-L425
On a related note, it might make sense to set this option to true instead, so that it always refreshes the rules (and also the webadmin) from the specified files. Otherwise I think it only updates when a user clicks the button on the admin panel (?). I would like some input from nixpkgs stalwart maintainers on this one @happysalada @onny @oddlama @Pandapip1
|
@norpol Seems to have been changed in this commit upstream: stalwartlabs/stalwart@38fa029 (0.11.0) |
96d1044 to
5c9b7d5
Compare
|
This line only creates an empty directory now: Safe bet would be to keep it for compatibility reasons, but practically it shouldn't be needed any longer. |
7c4e533 to
c3523d2
Compare
There was a problem hiding this comment.
This is already disabled by default, so explicitly setting it shouldn't make a difference. From https://stalw.art/docs/spamfilter/settings/general/#automatic-updates :
Stalwart can be configured to automatically update the spam-filter rules on startup. This feature is disabled by default and can be enabled by setting the spam-filter.auto-update key to true.
As for downloading the https:// URLs inside, I believe stalwart downloads them anyway. That setting seems to only affect this whether rules are reloaded on startup or not: https://github.com/stalwartlabs/stalwart/blob/b2f05254232a16873f260c527f327b9d3623b7f2/crates/common/src/manager/boot.rs#L413-L425
On a related note, it might make sense to set this option to true instead, so that it always refreshes the rules (and also the webadmin) from the specified files. Otherwise I think it only updates when a user clicks the button on the admin panel (?). I would like some input from nixpkgs stalwart maintainers on this one @happysalada @onny @oddlama @Pandapip1
2a2f76a to
8bfa972
Compare
8bfa972 to
51f8cf2
Compare
/etc/etc and bump to v0.12.5 + webadmin v0.1.28
|
Any reason for including the update to 0.12.5 here instead of on a separate PR? Edit: there are already open PRs that would update those packages:
|
6d578ba to
e0c982c
Compare
|
@diogotcorreia Just wanted to give the build a try, since there is plenty of feedback on the current PR I've switched it back to a draft since I'd expect more rounds. From the GitHub PRs in general it's not uncommon that one PR is addressing multiple things - although that makes back-porting sometimes harder. Just added the |
diogotcorreia
left a comment
There was a problem hiding this comment.
A few more nitpicks:
- add "Closes " for both the existing PRs that update stalwart (make sure to add "Closes" before both, otherwise they won't be closed)
- you probably should squash some of the commits (e.g., the ones fixing the spam-filter package should just be merged into the first some)
- the commit adding yourself to
maintainer-list.nixshould come first
Otherwise, LGTM I think
a58ced8 to
0d57c7f
Compare
|
Hey @diogotcorreia I've rebased and incoroporated your suggestions.
|
0d57c7f to
f64d755
Compare
/etc and bump to v0.12.5 + webadmin v0.1.28/etc and bump + patch mail from v0.12.4 to v0.12.5
21a84a3 to
c469e0e
Compare
/etc and bump + patch mail from v0.12.4 to v0.12.5/etc
c469e0e to
c8bd8fc
Compare
diogotcorreia
left a comment
There was a problem hiding this comment.
Sorry it took so long, I was busy for the past few days
LGTM!
|
Thanks @diogotcorreia. I've created a separate PR for #425489 in the meanwhile. |
|
There was a reply concerning asn.urls, |
Things done
spamfilter.tomlanylonger. This pull requests packages the spam-filter as an additional package.Note: Stalwart will still download additional data through the
spam-filter.toml. I don't think this has changed across the releases. I don't see that the ASN IPs, geolite, domains_mx, free_email_providers, ... are feasible to package into nixpkgs. So I'm not even sure whether it is advisable to not pull the spam-filters automatically from GitHub as well (so staying with the upstream config).Also I'm unsure whether the auto-update flag has only an impact on the filter rules or also the http URLs downloaded through the filters.
built generates the same result
nix.conf? (See Nix manual)sandbox = relaxedsandbox = truenix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)Add a 👍 reaction to pull requests you find important.