These classnotes are depreciated. As of 2005, I no longer teach the classes. Notes will remain online for legacy purposes

UNIX03/Configure SpamAssassin

Classnotes | UNIX03 | RecentChanges | Preferences

Difference (from prior major revision) (no other diffs)

Changed: 23c23,35
score BAYES_80 3.000
score BAYES_80 3.000

Setup Amavisd Home Directory



Now would probably be a good time to start to setup Amavisd's home directory. As you recall, we will be running Amavisd in a chroot jail. Thus, Amavisd's home directory must be a small subset of the filesystem containing all the necessary files for Amavisd to run.

One of the first things it will need is a .spamassassin configuration directory and it's own user_prefs file (for tweaking of the SpamAssassin settings).

So let's move into it's home directory at /var/lib/amavis, and create these files:
# cd /var/lib/amavis
# mkdir .spamassassin
# touch .spamassassin/user_prefs
# chown -R amavis.amavis .spamassassin


/etc/spamassassin/local.cf

Edit the SpamAssassin config file. Recall that by default this is /etc/mail/spamassassin/local.cf, but for Debian and Red Hat, this goes into /etc/spamassassin/local.cf. Recall our configuration file from before, and configure accordingly:
 rewrite_subject 1
 report_safe 0
 use_terse_report 0
 use_bayes 1
 bayes_path /var/lib/amavis/.spamassassin/bayes
 auto_learn 1
 skip_rbl_checks 1
 use_razor2 1
 use_dcc 1
 use_pyzor 0
 dcc_add_header 1
 dns_available yes
 header LOCAL_RCVD Received =~ /\S+\.domain\.com\s+\(.*\[.*\]\)/
 describe LOCAL_RCVD Received from local machine
 score LOCAL_RCVD -50
 ## Optional Score Increases
 score DCC_CHECK 4.000
 score RAZOR2_CHECK 2.500
 score BAYES_99 4.300
 score BAYES_90 3.500
 score BAYES_80 3.000

Setup Amavisd Home Directory

Now would probably be a good time to start to setup Amavisd's home directory. As you recall, we will be running Amavisd in a chroot jail. Thus, Amavisd's home directory must be a small subset of the filesystem containing all the necessary files for Amavisd to run.

One of the first things it will need is a .spamassassin configuration directory and it's own user_prefs file (for tweaking of the SpamAssassin settings).

So let's move into it's home directory at /var/lib/amavis, and create these files:

 # cd /var/lib/amavis
 # mkdir .spamassassin
 # touch .spamassassin/user_prefs 
 # chown -R amavis.amavis .spamassassin



Classnotes | UNIX03 | RecentChanges | Preferences
This page is read-only | View other revisions
Last edited June 7, 2003 1:52 am (diff)
Search:
(C) Copyright 2003 Samuel Hart
Creative Commons License
This work is licensed under a Creative Commons License.