To take full advantage of amavisd-new's built in support for multiple
instances with the -i flag, we need to be able to specify significantly
different SpamAssassin configurations for different instances. For this we
propose a global config variable, something like 'sa_local_dir'
(sa_site_dir?), which, if specified, is passed to Mail::SpamAssassin->new
as the site_rules_filename argument. The patch is trivial, 3 lines.
By specifying sa_local_dir in config files included by specific instances,
we can create a minimal amavsid-new (for milter) and full-featured
amavisd-new on the same box. It's good for disabling a lot of heavy SA
plugins, such as fuzzyocr.
also, the patch is against gentoo's 2.6.1-r1, rather than HEAD, sorry about
that.
it looks like this:
--- /usr/sbin/amavisd 2009-01-09 10:07:04.000000000 -0800
+++ /usr/sbin/amavisd 2009-01-09 09:58:35.000000000 -0800
@@ -343,7 +343,6 @@
)],
'confvars' => # global settings (not per-policy, not per-recipient)
[qw(
- $sa_local_dir
$myproduct_name $myversion_id $myversion_id_numeric $myversion_date
$myversion $instance_name @additional_perl_modules
$MYHOME $TEMPBASE $QUARANTINEDIR $quarantine_subdir_levels
@@ -20218,8 +20217,6 @@
};
if ($sa_version_num < 3.001005 && !defined $sa_args->{LOCAL_STATE_DIR})
{ $sa_args->{LOCAL_STATE_DIR} = '/var/lib' } # don't ignore sa-update
rules
- if (defined $sa_local_dir)
- { $sa_args->{site_rules_filename} = $sa_local_dir }
my($spamassassin_obj) = Mail::SpamAssassin->new($sa_args);
# $Mail::SpamAssassin::DEBUG->{rbl}=-3;
# $Mail::SpamAssassin::DEBUG->{rulesrun}=4+64;
Thanks,
noah
[email protected]
------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
AMaViS-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/