Hi - try this.
There should be a file in your /Library/Server/Mail/Config/Postfix directory called "virtual_users"
Add an entry
"jimsdomain.com" is your email domain and
"jim" is the Mac Account short name that you would like to receive any misaddressed mail to.
$ sudo postmap /Library/Server/Mail/Config/postfix/virtual_users
$ sudo postfix reload (or stop start mail via sudo serveradmin or via server.app)
Hope that helps!
Hmm -- that's a new place to try. FWIW, the appropriate file in that directory is "virtual" rather than "virtual_users", but it may be the right version of the file to try (i.e., not the one in /etc/postfix).
I have to say that starting the Server mail server royally screwed up mail delivery and receipt on my server. After several hours of dealing with rejected connections and the like, I shut it down and went back to my previous solution, MailServe from cutedgesystems.com. I'm in kind of a crunch on some other things right now, but I'll check into this when I get back into it. Thanks!
BTW, a followup question that should really be a separate issue -- If the "virtual" thing works, I assume that the "aliases" file in this directory would similarly be the right place to put aliases. Is this the only way to manage aliases with Server, or is there some hidden part of the app's UI to do this. (I don't think so, but...)
Actually - virtual_users is the file you want.
"virtual" is for a different purpose - virtual alias domains.
So you may need to create "virtual_users". Do a
$ cat main.cf | grep virtual and
$ cat main.cf | grep alias
To see where postfix wants to find things. You're right about the aliases file in this directory. Postfix seems to now want it here.
Here's a final tip. Set the response codes for unknown local user to 450 in main.cf while your mucking around. That way any mail not delivered will be sent again by the sending smtp server. This will keep the users happy!!
unknown_local_recipient_reject_code = 450
Reporting back --
* /Library/Server/Mail/Config/postfix does seem to be the right path -- when I launch the server app, main.cf gets a new modification date (even though the mail server is still disabled). So that's good news.
* Not much evidence of "virtual" stuff in main.cf -- grepping for "virtual" in main.cf returns only this:
#myhostname = virtual.domain.tld
# Do not specify the names of virtual domains - those domains are
# /etc/passwd, /etc/aliases, or the $virtual_alias_maps files.
# the $virtual_mailbox_maps files.
# - destinations that match $virtual_alias_domains,
# - destinations that match $virtual_mailbox_domains.
# local(8), relocated(5) and virtual(5) for the effects this has on
# aliases, canonical, virtual, relocated and .forward file lookups.
virtual_alias_maps = $virtual_maps
For that matter, there's no evidence of ANY .db files being accessed by main.cf, even though the postfix folder contains virtual_domains.db, system_user_maps.db, and rbl_whitelist.db. Meanwhile, the current contents of the "virtual" file is the man page for "virtual - Postfix virtual alias table format", which sure makes it sound like this is where user aliases should go. You've been really helpful, but I confess I'm more puzzled than ever... Thanks again!
rbut got the solutiuon, but just to make it a bit more clear:
1. Create a user in Server.app that you want to be the catch all account and enable email for it.
2. Open Workgroup Manager for 10.8 (http://support.apple.com/kb/DL1567)
3. Select the same user and doubleclick the row under the shortname (you can add aliases to the same account here too)
4. add "@<yourdomain>", save.
5. Verify by sending a test email to a non-existing email for the domain. (You may have to restart mailservice?)
I now do want to catch all email as it has become my lives work to report spam.
So I figured out an easier way to catch all email using simply the serveradmin command-line tool (this only takes email that would otherwise bounce):
sudo serveradmin settings mail:imap:lmtp_luser_relay_enabled = yes
sudo serveradmin settings mail:imap:lmtp_luser_relay = catchallusername
sudo postfix reload