[ingo] maildrop driver for ingo

Mathias Weyland mweyland at phys.ethz.ch
Fri Jul 22 08:47:20 PDT 2005


On Tue, Jul 19, 2005 at 10:06:48PM -0700, Rob Brandt wrote:
> I've just installed ingo from the HEAD snapshot of July 4.  The maildrop support
> is one of the main reasons I am upgrading to the new version.

Hi

Nice to hear you like the new features :). Please note that the code I wrote
is highly experimental. It's always risky to use HEAD snapshots since things 
may break or just fail to work properly.


>  I have used horde for several years, but never ingo because I've been using
> maildrop the whole time.  I'm looking forward to having an interface to
> manage this :)

If you manage to set it up correctly it will work (at least here it does).


> However, it's not working yet.  Several things aren't clear to me.  In
> backends.php, I've configured the maildrop stanza with my server info,
> including maildir and path to maildrop.


Can you show that stanza? This is mine:

$backends['maildrop'] = array(
    'driver' => 'vfs',
    'preferred' => '',
    'hordeauth' => 'full',
    'params' => array(
        // Hostname of the VFS server
        'hostspec' => 'localhost',
        // Name of the procmail config file to write
        'procmailrc' => 'mailfilter',
        // Port of the VFS server
        'port' => 21,
        // The VFS driver to use
        'vfstype' => 'ftp'
    ),
    'script' => 'maildrop',
    'scriptparams' => array(
        // What path style does the IMAP server use ['mbox'|'maildir']?
        'path_style' => 'maildir',
        // An array of variables to append to every generated script.
        // Use if you need to set up specific environment variables.
        'variables' => array(
            // Example for the $PATH variable
            // 'PATH' => '/usr/bin'
        )
    )
);

Note that the mailfilter file (which is the file where the user's rules
will be saved) has to be set with the key 'procmailrc'.

And it's not needed to provide the path to maildrop. Maildrop should be
called by the MTA and not by horde.

Concerning the maildir stuff, I guess you mean that you've set the
path_style to maildir (mbox does not work with subfolders). It's not needed
to set the path to the maildir here (see my comment about the global
maildroprc at the end of that email).


>  I expected then to be able to go into Setup and actually *select* maildrop
> as my filter backend, but my only option similar to that is "prefs". 

Same for me here. 'prefs' is the backend selected in the web interface. I
don't remember how ingo works with different backends, but I think you can
bind backands to the domains. (see the 'preferred' directive.)


> Oh well, I try running the filters anyway, and I can create one and apply 
> it, but there's no correlation between what it does and what's in my existing 
> maildrop file.

What did you set and what is in the file?


> * Do I need to do anything to designate maildrop as my filter backend?

You need a working vfs setup. I'm using proftpd with a special
authentification (against my mysql user database) for this.


> * Will ingo incorporate my existing maildrop filters, or do I have to enter them
> again?

You have to enter them again. It's rather difficult to write an import
function, and since I'm not in the need for such an import function it looks
like someone else has to write it :)


> * Does it matter that my mail path is different than what is listed below?  I am
> at /var/spool/postfix/virtual/(domain)/(user)/

That depends on your vfs driver. I configured proftpd to save the mailfilter
file in /home/vmail/user at domain/:

DefaultRoot /home/vmail/%u

I'm not quite sure what's the best way to configure this for your setup.
Maybe someone on the list has a good idea. (Maybe a second folder for the
mailfilter files if it's not possible to solve it differently)

And please note that you have to include the user's mailfilter file in your
global maildroprc. This looks like this for me (please note that I added
some features since the last posting):

([0.00][root at lists:/var/www/horde/ingo]) > cat /etc/maildroprc
# Global maildrop filter file

# Uncomment this line to make maildrop default to ~/Maildir for
# delivery- this is where courier-imap (amongst others) will look.
DEFAULT="${HOME}"
logfile "/home/vmail/maildrop.log"

# include user's mailfilter file if present
exception {
        include "${HOME}mailfilter"
}

# move mails tagged as spam in the spam folder if present
if( /^X-Spam-Flag: .*YES/ )
        exception {
           to "${DEFAULT}/.spam/"
        }

# move mails with VERP extensions into the appropriate folder if present.
exception {
        to "${DEFAULT}/.${1}/"
}

# safety fallback
to "${DEFAULT}"
([0.00][root at lists:/var/www/horde/ingo]) > 

To the ingo crew:
Are you looking for someone who maintains the maildrop driver? I'm planning
to make some improvements and I have contact to someone who is going to
write vacation support for the maildrop horde driver. I would volonteer for
maintaining ingo's maildrop filter.

Best regards

Mathias Weyland


More information about the ingo mailing list