2

I installed SSMTP to easily send emails from cli with GMail. There is a problem that all system messages from root (xy@gmail.com) are sent with email to ubuntuuser@gmail.com. How I can disable this?

ssmtp.conf:

# Config file for sSMTP sendmail
#
# The person who gets all mail for userids < 1000
# Make this empty to disable rewriting.
root=xy@gmail.com

# The place where the mail goes. The actual machine name is required no
# MX records are consulted. Commonly mailhosts are named mail.domain.com
mailhub=mail

# Where will the mail seem to come from?
rewriteDomain=gmail.com

# The full hostname
hostname=ubuntu

# Are users allowed to set their own From: address?
# YES - Allow the user to specify their own From: address
# NO - Use the system generated From: address
#FromLineOverride=YES

mailhub=smtp.gmail.com:587
UseTLS=Yes
UseSTARTTLS=YES
AuthUser=xy@gmail.com
AuthPass=12345

FromLineOverride=yes
  • 2
    In the revaliases file which is in the same folder try adding the alias as below root:xy@gmail.com:smtp.gmail.com:587 – Beniston Nov 3 '16 at 8:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.