Or how to configure postfix to useĀ  alias_domain table found in postfixadmin schema

Follow the closest howto (lacks domain aliases description) to setup the latest version of postfiadmin and make it work with your postfix.

Then add two other maps so it will look something like:

virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf, mysql:/etc/postfix/mysql_virtual_alias_alias_maps.cf
virtual_mailbox_maps = mysql:/etc/postfix/mysql_virtual_mailbox_maps.cf, mysql:/etc/postfix/mysql_virtual_mailbox_alias_maps.cf

you need these two to make postfix search for mailboxes or aliases in aliased domains, the corresponding queries are:

mysql:/etc/postfix/mysql_virtual_alias_alias_maps.cf :
query = SELECT goto FROM alias,alias_domain
  WHERE alias_domain.alias_domain = '%d'
  AND alias.address=concat('%u', '@', alias_domain.target_domain)
  AND alias.active = 1
mysql:/etc/postfix/mysql_virtual_mailbox_alias_maps.cf :
query = SELECT maildir FROM mailbox, alias_domain
  WHERE alias_domain.alias_domain = '%d'
  AND mailbox.username=concat('%u', '@', alias_domain.target_domain )
  AND mailbox.active = 1

Nothing special, rather for myself to remember

Post Navigation