> However messages coming from smtp, qmqp and qmtp input _do_not_ go
> through qmail-inject.
>
> What you can do, is capture all outgoing mail from your domain in a
> directory, and have a program deliver them through qmail-inject. This
> program must set the QMAILUSER, QMAILNAME and QMAILHOST environment
> variables according to the mail headers, so it should parse the message.
>
I have tried this :
I capture all emails :
/var/qmail/control/virtualdomains
:alias-fai
In inject all the messages in a script called inject-filter :
/var/qmail/alias/.qmail-fai-default :
| /var/qmail/bin/inject-filter
Contents of inject-filter :
#!/bin/sh
QMAILINJECT=f
QMAILUSER="Nord.Bassin"
QMAILHOST="netsante.fr"
QMAILNAME="SEL Nord Bassin"
SENDER="[EMAIL PROTECTED]"
export QMAILINJECT QMAILUSER QMAILHOST QMAILNAME
qmail-inject
The problem is when a mail is received, It generate
a loop witch never stop :
mail received by smtp -> (virtual domain )inject-filter -> mail
re-injected via qmail-queue
| |
------------------<------------------
David ROBERT.