[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[msmtp-users] Mail to root



I'm using msmtp on my desktop machine to get output from cron jobs, etc at my usual email address instead of a local mailbox.

Unforunately, cron will sometimes send email to root, and msmtp will try to deliver such messages to root on my ISP's SMTP server, leading to cranky phone calls from their sysadmins.

I can set the MAILTO environment variable in cron. But if I screw that up, or some other program decides to send mail to root, I'll have the same problem, and I won't know it's happening until the poor admin gets sick of it and calls me again.

Is there a way for smtp to either a) use an alias for root or b) reject email when the to address has no domain? Or is there some other way around this problem?