- Plesk 12.5 for Linux
- Plesk 11.x for Windows
How to set spam filter settings for bunch of email accounts avoiding configuration of Spamassassin on server level in Plesk for Windows?
Plesk GUI and
utility do not support multiple mail accounts management at once. Instead, a script can be used to update multiple mailboxes simultaneously:
list.txtfile that contains all mailboxes that require modification by SpamAssassin. The list should look like:
In C:\ directory, create
script.batfile with the following content:
for /f "tokens=*" %%a in (C:\\list.txt) do "C:\\Program Files (x86)\\Parallels\\Plesk\\bin\\spamassassin.exe" --update %%a -hits 6 -action del -blacklist add:firstname.lastname@example.org
This command modifies the SpamAssassin configuration on all emails listed in list.txt: sets the number of hits sufficient to consider a letter as spam to 6, orders to delete spam, and puts the email@example.com email address to the black list.
Run the script in a command line:
For details about spam settings management via Plesk CLI, visit:
213412289 [How to] Manage spam settings in Plesk via CLI?