Mailing List Archive

program to deliver from sendmail to Maildir?
Evan Champion <evanc@synapse.net> asks:
>
>Is there a program I can use to deliver from sendmail to Maildir (like
>mail.local)?
>

I'm not aware of anything like that (unless I wanted to be facetious
and say there are five: qmail-inject, qmail-queue, qmail-send,
qmail-lspawn, and qmail-alias).

Judging by the qmail-alias man page, gluing sendmail to qmail-alias
wouldn't be easy. Qmail-alias wants its stdin to be a seekable file
rather than a pipe as sendmail (to the best of my memory) wants to
provide.

-Greg
--
Greg Andrews West Coast Online
Unix System Administrator 5800 Redwood Drive
gerg@wco.com Rohnert Park CA 94928
(yes, 'greg' backwards) 1-800-WCO-INTERNET
Re: program to deliver from sendmail to Maildir? [ In reply to ]
On Fri, 21 Feb 1997, Greg Andrews wrote:

> I'm not aware of anything like that (unless I wanted to be facetious
> and say there are five: qmail-inject, qmail-queue, qmail-send,
> qmail-lspawn, and qmail-alias).

Well, I don't mind that, as long as you can think of a way for sendmail
to deliver to one of those :-)

Is there a way to get sendmail to redeliver to another port on the same
machine? I could set up a qmail-smtpd and then get it to deliver to the
Maildir.

Evan
--
Evan Champion * Director, Network Operations
mailto:evanc@synapse.net * Directeur, Exploitation du reseau
http://www.synapse.net/ * Synapse Internet
program to deliver from sendmail to Maildir? [ In reply to ]
Greg Andrews writes:
> Evan Champion <evanc@synapse.net> asks:
> >
> >Is there a program I can use to deliver from sendmail to Maildir (like
> >mail.local)?
> >
>
> I'm not aware of anything like that

It's easy to deliver to a Maildir using the program given below. Just
convince sendmail to use this program as a local delivery mailer.

#!/usr/bin/perl

$fn = time.".$$.$0";
open(MAILDIR, ">Maildir/tmp/$fn") || die "$0:open failed:$!";
while(<>) { print MAILDIR || die "$0:write failed:$!"; }
close(MAILDIR) || die "$0:close failed:$!";
rename("Maildir/tmp/$fn", "Maildir/new/$fn") || die "$0:rename failed:$!";

--
-russ <nelson@crynwr.com> http://www.crynwr.com/~nelson
Crynwr Software sells network driver support | PGP ok
521 Pleasant Valley Rd. | +1 315 268 1925 voice | Peace, Justice, Freedom:
Potsdam, NY 13676-3213 | +1 315 268 9201 FAX | pick two (only mostly true)