My pretty face [ László Monda's Blog ]
Exploring the cyberspace, one quadrant at a time!

SMTP relaying with Postfix through GMail

cat << END >> /etc/postfix/main.cf
smtp_sasl_auth_enable = yes
smtp_use_tls = yes
smtp_sasl_tls_security_options = noanonymous
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
relayhost = smtp.gmail.com
END

echo "smtp.gmail.com youraccount@gmail.com:yourpassword" >> /etc/postfix/sasl_passwd
postmap /etc/postfix/sasl_passwd
/etc/init.d/postfix restart

Leave a Reply

Line and paragraph breaks automatic.
XHTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="" highlight="">