Part 1: Installing CyrusImapd? | ||||||||||
| Line: 148 to 148 | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|
Test your new setup immediately. If anything went wrong, you could possibly be losing mail. If it isn't verifiably working at this point, type cd /etc/mail; make stop to stop SendMail until you either correct the problem or revert to a previous working setup.
-- KirkStrauser - 03 Jul 2003
| ||||||||||
| Added: | ||||||||||
| > > |
Alternative recipiesIt is possible to make sendmail check existence of cysus mailboxes before replying to "RCPT TO:". The required configuration is described at Real Time Cyrus (and sendmail) Integration Version 2 Andrzej Adam Filip 2004-12-19 | |||||||||
| ||||||||||
Part 1: Installing CyrusImapd? | ||||||||
| Line: 43 to 43 | ||||||||
|---|---|---|---|---|---|---|---|---|
If you want to use Cyrus to deliver mail locally (and most people do):
| ||||||||
| Changed: | ||||||||
| < < |
| |||||||
| > > |
| |||||||
define(`confLOCAL_MAILER',`cyrusv2') MAILER(cyrusv2) | ||||||||
| Line: 64 to 64 | ||||||||
A Note About SpamAssassinIf you want to use SpamAssassin with your new setup, then follow the instructions at FilterMailWithSpamAssassin to install it. | ||||||||
| Changed: | ||||||||
| < < |
I highly recommend using the FilterMailWithSpamAssassinViaMilter method of using a SendMail? "milter" to process your mail. | |||||||
| > > |
I highly recommend using the FilterMailWithSpamAssassinViaMilter method of using a SendMail "milter" to process your mail. | |||||||
It's far easier to configure and is completely independent of your SendMailAndCyrus setup. However, if you have a firmly entrenched ProcMail? setup, then you'll want to work through the following directions.
Using ProcMail for local delivery with SpamAssassin | ||||||||
| Line: 78 to 78 | ||||||||
SendMail? configuration
| ||||||||
| Changed: | ||||||||
| < < |
| |||||||
| > > |
| |||||||
FEATURE(local_procmail) | ||||||||
| Line: 145 to 145 | ||||||||
Part 3: Testing! | ||||||||
| Changed: | ||||||||
| < < |
Test your new setup immediately. If anything went wrong, you could possibly be losing mail. If it isn't verifiably working at this point, type cd /etc/mail; make stop to stop SendMail? until you either correct the problem or revert to a previous working setup.
| |||||||
| > > |
Test your new setup immediately. If anything went wrong, you could possibly be losing mail. If it isn't verifiably working at this point, type cd /etc/mail; make stop to stop SendMail until you either correct the problem or revert to a previous working setup.
| |||||||
-- KirkStrauser - 03 Jul 2003
| ||||||||
Part 1: Installing CyrusImapd? | ||||||||||
| Line: 61 to 61 | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| /etc/mail# make; make install; make restart | ||||||||||
| Changed: | ||||||||||
| < < |
Using ProcMail for local delivery | |||||||||
| > > |
A Note About SpamAssassinIf you want to use SpamAssassin with your new setup, then follow the instructions at FilterMailWithSpamAssassin to install it. I highly recommend using the FilterMailWithSpamAssassinViaMilter method of using a SendMail? "milter" to process your mail. It's far easier to configure and is completely independent of your SendMailAndCyrus setup. However, if you have a firmly entrenched ProcMail? setup, then you'll want to work through the following directions.Using ProcMail for local delivery with SpamAssassin | |||||||||
ProcMail cannot deliver directy to a CyrusImapd? mail folder. However, you can configure it to use cyrus' deliver program to handle the actual delivery.
| ||||||||||
| Line: 139 to 145 | ||||||||||
Part 3: Testing! | ||||||||||
| Changed: | ||||||||||
| < < |
Test your new setup immediately. If anything went wrong, you could possibly be losing mail. If it isn't verifiably working at this point, type cd /etc/mail; make stop to stop SendMail? until you either correct the problem or revert to a previous working setup.
-- KirkStrauser - 01 Apr 2003
| |||||||||
| > > |
Test your new setup immediately. If anything went wrong, you could possibly be losing mail. If it isn't verifiably working at this point, type cd /etc/mail; make stop to stop SendMail? until you either correct the problem or revert to a previous working setup.
| |||||||||
| Added: | ||||||||||
| > > |
-- KirkStrauser - 03 Jul 2003 | |||||||||
| ||||||||||
Part 1: Installing CyrusImapd? | ||||||||
| Line: 69 to 69 | ||||||||
|---|---|---|---|---|---|---|---|---|
| If you need to use ProcMail to sort your mail, then: | ||||||||
| Added: | ||||||||
| > > |
SendMail? configuration | |||||||
| ||||||||
| Line: 81 to 83 | ||||||||
| MAILER(local) MAILER(smtp) | ||||||||
| Added: | ||||||||
| > > |
Create the spam-processing pipeChoose your approach. You can either create your own wrapper forspamc and deliver, or you can use mailcheck.py from SpamAssassin. Advantage of the first option: you don't have to have Python installed on the server. Advantage of the second option: it's easier, and spamcheck.py uses lmtp to deliver the email directly to cyrus instead of calling the deliver program. This allows you to use some of CyrusImapd?'s nifty features, such as SortingMailWithSieve?.
Option 1: Roll-your-own solution with
| |||||||
# cat /usr/local/etc/procmailrc | ||||||||
| Line: 99 to 108 | ||||||||
formail -I"From " | spamc -u $LOGNAME | /usr/local/cyrus/bin/deliver -a $LOGNAME -m user.$LOGNAME
| ||||||||
| Added: | ||||||||
| > > |
Option 2:
# cd /usr/ports/mail/p5-Mail-Sp # make extract # cp work/Mail-SpamAssassin-2.50/contrib/spamcheck.py /usr/local/bin/ # make clean
# cat /usr/local/etc/procmailrc DROPPRIVS=no :0fw | /usr/local/bin/spamcheck.py -s nobody -r $LOGNAME -l unix:/var/imap/socket/lmtp Putting the new setup into action | |||||||
/etc/mail# make; make install; make restart | ||||||||
| Line: 1 to 1 | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Added: | |||||||||||||
| > > |
Part 1: Installing CyrusImapd?Installing CyrusImapd? on FreeBSD is pretty simple:
# cat testmail To: somemailuser From: someoneelse Subject: Test email This is a testand sending it to cyrus' deliver program:
# cat testmail | /usr/local/cyrus/bin/deliver -a somemailuser -m user.somemailuserThen, use any standard mail client (or telnet, if you prefer) to verify that the email was delivered to somemailuser's account. Part 2: Configuring SendmailUsing Cyrus for local deliveryIf you want to use Cyrus to deliver mail locally (and most people do):
define(`confLOCAL_MAILER',`cyrusv2') MAILER(cyrusv2)
/root# cd /etc/mail; tail -n 4 host.domain.com.mc define(`confLOCAL_MAILER',`cyrusv2') MAILER(cyrusv2) MAILER(local) MAILER(smtp)
/etc/mail# make; make install; make restart Using ProcMail for local deliveryProcMail cannot deliver directy to a CyrusImapd? mail folder. However, you can configure it to use cyrus'deliver program to handle the actual delivery.
If you're using ProcMail to send email through SpamAssassin before delivery, read the SpamAssassinAndCyrus topic and then follow the steps below.
If you need to use ProcMail to sort your mail, then:
FEATURE(local_procmail)
/root# cd /etc/mail; tail -n 3 host.domain.com.mc FEATURE(local_procmail) MAILER(local) MAILER(smtp)
# cat /usr/local/etc/procmailrc DROPPRIVS=no :0fw | /usr/local/bin/procmail-cyrus-delivery.sh $LOGNAME
# cat /usr/local/bin/procmail-cyrus-delivery.sh #!/bin/sh LOGNAME=$1 formail -I"From " | spamc -u $LOGNAME | /usr/local/cyrus/bin/deliver -a $LOGNAME -m user.$LOGNAME
/etc/mail# make; make install; make restart Part 3: Testing!Test your new setup immediately. If anything went wrong, you could possibly be losing mail. If it isn't verifiably working at this point, typecd /etc/mail; make stop to stop SendMail? until you either correct the problem or revert to a previous working setup.
-- KirkStrauser - 01 Apr 2003
| ||||||||||||