0
0
mirror of https://github.com/postfixadmin/postfixadmin.git synced 2024-09-20 03:36:20 +02:00

Merge pull request #324 from smhessenauer/master

fetchmail dovecot delivery
This commit is contained in:
David Goodwin 2020-02-12 09:07:46 +00:00 committed by GitHub
commit 666bb0218a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 1 deletions

15
ADDITIONS/fetchmail.pl Normal file → Executable file
View File

@ -29,6 +29,12 @@ our $db_password="CHANGE_ME!";
# Where to create a lockfile; please ensure path exists.
our $run_dir="/var/run/fetchmail";
# in case you want to use dovecot deliver to put the mail directly into the users mailbox,
# set "mda" in the fetchmail table to the keyword "dovecot".
# Where the delivery binary is located
$dovecot_deliver = "/usr/lib/dovecot/deliver";
# instead of changing this script, you can put your settings to /etc/mail/postfixadmin/fetchmail.conf
# just use perl syntax there to fill the variables listed above (without the "our" keyword). Example:
# $db_username = 'mail';
@ -105,7 +111,14 @@ map{
$cmd="user '${src_user}' there with password '".decode_base64($src_password)."'";
$cmd.=" folder '${src_folder}'" if ($src_folder);
$cmd.=" mda ".$mda if ($mda);
if ($mda) {
if ($mda eq "dovecot") {
$cmd.=" mda \"${dovecot_deliver} -d ${mailbox}\" ";
} else {
$cmd.=" mda ".$mda
}
}
# $cmd.=" mda \"/usr/local/libexec/dovecot/deliver -m ${mailbox}\"";
$cmd.=" is '${mailbox}' here";

View File

@ -22,6 +22,7 @@ Version X.X - master
- Sqlite improvements (see https://github.com/postfixadmin/postfixadmin/issues/177 and https://github.com/postfixadmin/postfixadmin/issues/176 )
- MySQL 8 compatibility (see https://github.com/postfixadmin/postfixadmin/pull/175 )
- Internally the database functions have been refactored to use PDO rather than the lower level mysql_, mysqli_, pg_ etc functions. ( see: https://github.com/postfixadmin/postfixadmin/pull/231 )
- Usage of dovecot deliver as fetchmail mda
Version 3.2 - 2018/05/02
-------------------------------------------------