You have been asked to create a sendmail configuration that sends all local mail to a mail hub, while directly delivering mail addressed to external systems.
Create a sendmail configuration containing the
MAIL_HUB define to identify the mail relay host for local mail. Use the
LOCAL_USERcommand to exempt the root user’s mail from relaying. Here are sample commands:
dnl Define a relay server for local mail define(`MAIL_HUB', `smtp.wrotethebook.com') dnl Users whose mail is not passed to the mail hub LOCAL_USER(root)
Rebuild and reinstall sendmail.cf, and then restart sendmail.