OK,
I have vaguely fleshed out some files here:
https://github.com/reetp/smeserver-SMEOptimizerSome notes/ comments:
I have physically added the qpsmptd/plugin to the rpm. The script can check for updates to this
I can't see the /etc/mail/spamassassin/smeoptimizer.cf on my testbox - I would have added it otherwise
DB needs to be created manually. Ideally it should be created from the RPM and a random password used
These keys could be in a DB entry (and later in a server-panel):
-alerts=[Yes|No]: Enable checks and alerts for SME server downtime or registration in DNS Blacklist - default Yes.
-contact=[Email]: Set the contact email address where alerts are sent to - default admin@<your domain>.
-VTAPI=[API Key]: This is the VirusTotal public API key used to check attachments (will remain local).
-DNSBL=[qpsmtpd|sa]: This configures whether the DNS blacklist lookup rejects directly (qpsmtpd) or scores (sa=SpamAssassin).
A smeoptimizer enabled/disabled key could also be added
e.g.
config set smeoptimizer service alerts Yes contact admin@somewhere.com VTAPI 12345wxyz DBSBL qpsmtpd
[root@test plugins]# config set smeoptimizer service alerts Yes contact admin@somewhere.com VTAPI 12345wxyz DBSBL qpsmtpd
[root@test plugins]# config show smeoptimizer
smeoptimizer=service
DBSBL=qpsmtpd
VTAPI=12345wxyz
alerts=Yes
contact=admin@somewhere.com
Those would need some rewriting in the main script, and with some files being templated in the RPM some of the setup/init stuff would not be required, but I do not want to touch the script right now !
You can either fork the repo or I can add you as a contributor if you are interested in helping.
To test:
Copying over the files manually
Add the DB
Run the file
/usr/local/smeoptimizer/SMEOptimizer.pl --initialize
See what breaks......
B. Rgds
John