User Tools

Site Tools


mail:spamassain_gateway

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
mail:spamassain_gateway [2013/03/19 13:34]
tschulz [/etc/rc.conf]
mail:spamassain_gateway [2013/03/22 06:08] (current)
tschulz [Spam Assassin Gateway (FreeBSD 9.1)]
Line 1: Line 1:
-====== ​Spam Assassin ​Gateway (FreeBSD 9.1) ======+====== ​SpamAssassin with MySQL Gateway (FreeBSD 9.1) ======
  
 ===== /​var/​db/​ports/​p5-Mail-SpamAssassin/​options ===== ===== /​var/​db/​ports/​p5-Mail-SpamAssassin/​options =====
Line 23: Line 23:
  
 ===== Install Ports ===== ===== Install Ports =====
 +Run the following commands to install the required ports
 <​file>​ <​file>​
 cd /​usr/​ports/​mail/​p5-Mail-SpamAssassin cd /​usr/​ports/​mail/​p5-Mail-SpamAssassin
Line 29: Line 30:
 make install make install
 cd /​usr/​ports/​mail/​spamass-milter/​ cd /​usr/​ports/​mail/​spamass-milter/​
 +make install
 +cd /​usr/​ports/​databases/​mysql55-server/​
 make install make install
 </​file>​ </​file>​
- 
 ===== /​etc/​rc.conf ===== ===== /​etc/​rc.conf =====
 Add the following to /​etc/​rc.conf Add the following to /​etc/​rc.conf
Line 39: Line 41:
 spamass_milter_enable="​YES"​ spamass_milter_enable="​YES"​
 spamass_milter_socket="​inet:​9999@127.0.0.1"​ spamass_milter_socket="​inet:​9999@127.0.0.1"​
 +mysql_enable="​YES"​
 ... ...
 </​file>​ </​file>​
  
 +===== Setup Database =====
 +<​file>​
 +/​usr/​local/​etc/​rc.d/​mysql-server start
 +</​file>​
 +Run the following in a mysql prompt to create a database
 +<​file>​
 +create database SpamAssassin;​
 +quit
 +</​file>​
 +create the required tables
 +<​file>​
 +cd /​usr/​local/​share/​doc/​p5-Mail-SpamAssassin/​sql
 +mysql SpamAssassin < awl_mysql.sql
 +mysql SpamAssassin < userpref_mysql.sql
 +mysql SpamAssassin < bayes_mysql.sql
 +</​file>​
 ===== local.cf ===== ===== local.cf =====
-default: /​usr/​local/​etc/​mail/​spamassassin/​local.cf+  * default: /​usr/​local/​etc/​mail/​spamassassin/​local.cf 
 +  * replace **USERNAME** and **PASSWORD** with the correct values
 <file config local.cf>​ <file config local.cf>​
 user_scores_dsn DBI:​mysql:​SpamAssassin:​localhost user_scores_dsn DBI:​mysql:​SpamAssassin:​localhost
Line 61: Line 81:
 bayes_sql_password **PASSWORD** bayes_sql_password **PASSWORD**
 </​file>​ </​file>​
 +
 +That's it restart and the milter will be listening of port 9999
mail/spamassain_gateway.1363718085.txt.gz · Last modified: 2013/03/19 13:34 by tschulz