[Raw Msg Headers][Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Virtual domains?

Oliver Xymoron <oxymoron@waste.org>
> Sounds easy - which .cf file should that go in? A grep for rules doesn't
> find much.

Either crossbar.cf or aliases.cf should suit your needs.  aliases.cf
sounds best - at the start of routeuser, before the

	case "$(channel $quad)" in

check whether $(host $quad) is your virtual host, and rewrite $quad if
it is.  I haven't tested this:

	[ "$(host $quad)" = urka.com ] &&
		quad=(local $(user $quad) burka $(attributes $quad))

but I think it will redirect all mail for *@urka.com to the local user
or alias burka, which Iassume is what you want to do.

(I do this in crossbar.cf, which is a bit messy but allows me to take
the sender address into account when rewriting the destination address
- don't ask :)