[prev in list] [next in list] [prev in thread] [next in thread] 

List:       postfix-users
Subject:    Re: .forward, vacation, and bashslash username support
From:       Dominic Lai <dominic () ust ! hk>
Date:       2020-08-28 4:04:19
Message-ID: 6c5edfaf-c8f5-8ad8-472b-5f35b593a29f () ust ! hk
[Download RAW message or body]

Yes, thanks for your suggestion.  I tried it and it works.

I kept on thinking that it would work if I just set:

mydestination = postfix-server.mydomain.com $myhostname

would work (I have set myhostname=postfix-server.mydomain.com).

It turns out that I also need to set myorigin, and also need to
specifically set "mydestination = $myorigin ....".

Now, both \username and |/usr/bin/vacation work as expected!
Thanks!

Dominic


On 28/8/2020 11:47 am, Viktor Dukhovni wrote:
> On Fri, Aug 28, 2020 at 03:42:20AM +0000, Dominic Lai wrote:
> 
>> Aug 28 10:11:36 postfix-server postfix/local[3915542]: 2D8F33028D88:
>> to=<username@postfix-server.mydomain.com>, relay=local,
>> delay=0.06, delays=0.05/0/0/0.01, dsn=5.4.6, status=bounced (mail
>> forwarding loop for username@postfix-server.mydomain.com)
>>
>> When I look at dovecot log (I have got mail_log plugins on), and
>> I note that postfix bounced this message even before handling it
>> to dovecot-lda (ie. dovecot-lda does not even record any handling of
>> this transaction).
>>
>> However, if I changed the .forward as follows:
>>
>> username@localhost, "|/usr/bin/vacation username"
>>
>> Then vacation works, username can also receive a copy of email.
> 
> This likely because $myorigin is not listed in $mydestination,
> and so just a bare "username" in aliases(5) or .forward files
> is not a reference to an address in "local" address class.
> 
> You either need to ensure that $myorigin is listed in
> $mydestination, or else to use explicit local domains
> in .forward files and aliases(5) files as you noted.
> 


-- 
Dominic Lai
Department of Computer Science and Engineering
HKUST
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic