More robust mailer configuration