Hi,

I am using the following perl script. Previously I used a different 
script with exec instead of system. Can anyone check if this is 
working now and does what i expect?

REMARK: I tried it, and now I found 327 message in my mailbox, which 
are copies of the same messages ... so, I advise not to use this 
script...
_Ace

file qmail-domainforward.pl
---------------------------
#!/usr/bin/perl
$uservariable="$ENV{LOCAL}\@$ARGV[0]";
my $exit = system "/var/qmail/bin/qmail-inject",$uservariable;
$exit /= 256;
$exit || print "Problem with Domain Forwarding (Could not execute 
qmail-inject)" && exit 111;
--------
end file

Then, in your ldap database, use 
deliveryprogrampath: preline /usr/sbin/qmail-domainforward.pl 
domain2.com

(all on one line of course)

Greetings,
Ace Suares


| Ace Suares, Internet Consultancy and Training
| Keizersgracht 132, 1015 CW AMSTERDAM, NL
| phone: 06 557 06 554    (+31 6 557 06 554)
| fax: 08 48 707 705      (+31 84 870 770 5)
| mailto:[EMAIL PROTECTED] PGP Key idea: 0x39B81FE5
| http://www.suares.com

Reply via email to