1. add into /etc/postfix/main.cf file;
relayhost = [domain.com]:25
smtp_sasl_auth_enable = no
smtp_sasl_password_maps = hash:/etc/postfix/sasl/sasl_passwd
smtp_sasl_security_options = noanonymous
smtp_tls_CAfile = /etc/postfix/cacert.pem
smtp_use_tls = yes
save and close
2. add login credentials into /etc/postfix/sasl/sasl_passwd
domain.com email@domain.com:password
save and close
3. create hash database from sasl_passwd file
sudo postmap sasl_passwd
sudo chmod 640 /etc/postfix/sasl/sasl_passwd
sudo chmod 640 /etc/postfix/sasl/sasl_passwd.db
4. test send mail.
echo "Tested" | mailx -r email@domain.com -s "Testing Gmail Relay2" email2@domain.com
5. Tips:
http://www.postfix.org/TUNING_README.html#mailing_tips
https://wiki.deimos.fr/Postfix:_limit_outgoing_mail_throttling
https://www.howtoforge.com/community/threads/limit-outgoing-number-of-messages-in-postfix.41131/