I have postfix and virtual domains, how do I add a .forward file for a
specific virtual user?
I have
virtual_mailbox_base = /srv/mail
in main.cf. I tried creating a .forward file in /srv/mail/domain/user/ (where
mail is delivered) and also /srv/mail/.forward+user@domain but it did not
work.
postconf -d|grep forward_path
forward_path = $home/.forward${recipient_delimiter}${extension},
$home/.forward
.forward processing is implemented in the local(8) delivery
agent, so that won't work with virtual mailbox users.
Instead add an entry for the user in virtual_alias_maps.
--
Noel Jones
OK, does not look like the best solution, but adding a new transport in
master.cf with hardcoded path the mailbox did the job. Anyone has a better
idea how to make maildrop without hardcoding the path to the mailbox?
OK, here are few details about the setup, let me know if you need more info:
Distro: Ubuntu 6.06 TLS
postfix 2.2.10, maildrop 1.5.3, libsasl2 2.1.19 from standart ubuntu packages
postfix is configured with virtual users, lookups are made in mysql.
In the standart configuration, maildrop transport is defined as `maildrop -d
${recipeint}`, which doen not work (out of the box) with virtual users.
$nexthop is also not a solution it sometime expands to dummy. To prove it I
replaced /usr/bin/maildrop with a simple bash script:
#!/bin/bash
echo "$@" >> /tmp/_debug
and it turns out $nexthop resolves ti dummy. I have a 'user@domain
maildrop:dummy' line in transport maps.
I tried with 'user@domain maildrop' and it seems to expand nexthop properly,
which is much better than the hadcoded link. Anyway, I`d be interested to see
how maildrop can be used with authlib against the same sql that postfix uses.
Please stop saying "it does not work". It does work here since years.
Please describe your problem: what exactly happens, what error you see,
... etc.
You may be a victim of a packaging bug. find the sources of the maildrop
package on ubuntu, then grep HAVE_COURIER in the patch files (*.patch).
if you find some, shoot the package maintainer ;-p (HAVE_COURIER is for
use with the courier-mta, not with postfix or other MTAs).
> $nexthop is also not a solution it sometime expands to dummy.
Nothing works if you fight against yourself ;-p
> To prove it I
> replaced /usr/bin/maildrop with a simple bash script:
>
> #!/bin/bash
> echo "$@" >> /tmp/_debug
>
> and it turns out $nexthop resolves ti dummy. I have a 'user@domain
> maildrop:dummy' line in transport maps.
>
why do you put "dummy" in the transport entry.
> I tried with 'user@domain maildrop' and it seems to expand nexthop properly,
> which is much better than the hadcoded link. Anyway, I`d be interested to see
> how maildrop can be used with authlib against the same sql that postfix uses.
>
I use the config with ${nexthop} (yes with authdaemon, mysql ...) on a
NetBSD system.