What type of hardware are you using: VPS bought online
What YunoHost version are you running: 12.1.36
How are you able to access your server: The webadmin
SSH
Describe your issue
I am trying to get a catch-all address working on a domain that also has some existing addresses which should continue to work. Example:
- alice@example.com for yunohost user alice
- bob@example.com for yunohost user bob
And now I want to also accept emails at whatever@example.com and give them to bob. So I use the modification described by @xananax at Catch-All address · Issue #557 · YunoHost/issues · GitHub which adds a hash table as the end of virtual_alias_maps.
But now all emails arrive in the account of bob, even those sent to alice@example.com ![]()
If I understand it correctly this happens because postfix first uses virtual_alias_maps and only after that (if it has not found a match yet) it will look into the virtual_mailbox_maps setting that tells it how to find the yunohost accounts, correct?
So then I tried putting the extra hash table at the end of the virtual_mailbox_maps setting instead. But that does not give me a working catch-all address, mails to whatever@example.com are then rejected.
So long story short: how can I have a catch-all address but still keep the mail for existing yunohost users on the same domain delivered to them and not to the catch-all account? ![]()
Thank for any help!
Share relevant logs or error messages
Relevant part of /etc/postfix/main.cf:
# this way bob gets all the mail and alice nothing:
virtual_mailbox_maps = ldap:/etc/postfix/ldap-accounts.cf,hash:/etc/postfix/app_senders_login_maps
virtual_alias_maps = ldap:/etc/postfix/ldap-aliases.cf,ldap:/etc/postfix/ldap-groups.cf,hash:/etc/postfix/my-catchalls
# this way the catch-all does not work, email to whatever@example.com is rejected.
virtual_mailbox_maps = ldap:/etc/postfix/ldap-accounts.cf,hash:/etc/postfix/app_senders_login_maps,hash:/etc/postfix/my-catchalls
virtual_alias_maps = ldap:/etc/postfix/ldap-aliases.cf,ldap:/etc/postfix/ldap-groups.cf