Has anyone worked out a system so that each user has "learn spam" "learn ham" folders in IMAP? What I would like is to for users to be able to drag a spam message into one of these folders and for sa_learn to be called.
I’ve found various cron job solutions that would monitor these folders, but that sounds like a PITA to implement for a lot of domains. I was hoping there was something more callback-style that was implemented in dovecot or postfix that would fire off sa_learn when the either of the “learn” folders was called.
Optionally, it would be cool that after you dropped it into the "learn ham" folder it would strip off the spamassassin junk and drop it back into your inbox.
Has anyone done this yet under virtualmin?
I’ve just made two commands for learning spam/ham
/usr/bin/sa-learn --spam /home//homes//Maildir/.Junk/cur[/code:1]
/usr/bin/sa-learn --ham /home//homes//Maildir/.Ham/cur[/code:1]
and call them with a cron job
Post edited by: fdzicher, at: 2009/05/16 00:58<br><br>Post edited by: fdzicher, at: 2009/05/16 00:58
I finally got around to making the script that I wanted.
This will tkae things from the ‘ham’ folder, clean them up, and return them to the inbox.
Thanks for the start Frank, that helped a lot!
Download it from here :
Awesome guys! Thanks!
Was able to use the script and modify slightly to suit my needs. (Remove both spam and ham from folders, rather than moving ham back to inbox.)