Differences
This shows you the differences between two versions of the page.
| sendgrid [2015/06/01 23:25] – created - external edit 127.0.0.1 | sendgrid [2025/07/21 09:06] (current) – removed steve | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | ====== SendGrid ====== | ||
| - | * [[Mail Servers]] | ||
| - | * [[monit]] | ||
| - | * [[Postfix]] | ||
| - | * [[Software as a Service|SaaS]] | ||
| - | |||
| - | * [[http:// | ||
| - | * [[http:// | ||
| - | |||
| - | |||
| - | SendGrid is a cloud server for sending out e-mails. | ||
| - | ==== Configuration ==== | ||
| - | |||
| - | * 25 - TLS/plain | ||
| - | * 465 - SSL | ||
| - | * 587 - TLS/plain | ||
| - | |||
| - | Sendgrid recommends using port 587. | ||
| - | |||
| - | === SSMTP === | ||
| - | |||
| - | < | ||
| - | mailhub=smtp.sendgrid.net: | ||
| - | AuthUser=sendgridusername | ||
| - | AuthPass=sendgridpassword | ||
| - | UseSTARTTLS=YES | ||
| - | </ | ||
| - | |||
| - | === Postfix === | ||
| - | |||
| - | Here are the lines for ''/ | ||
| - | |||
| - | < | ||
| - | smtp_sasl_auth_enable = yes | ||
| - | smtp_sasl_password_maps = static: | ||
| - | smtp_sasl_security_options = noanonymous | ||
| - | smtp_tls_security_level = may | ||
| - | header_size_limit = 4096000 | ||
| - | relayhost = [smtp.sendgrid.net]: | ||
| - | </ | ||
| - | |||
| - | Make sure to restart Postfix once these changes are done. | ||
| - | |||
| - | < | ||
| - | / | ||
| - | </ | ||
| - | |||
| - | Note: If you are getting no mechanism available error messages it generally indicates that you may be missing some SASL authentication libraries. In this case you may want to: | ||
| - | |||
| - | < | ||
| - | apt-get install libsasl2-modules | ||
| - | </ | ||
| - | |||
| - | or on a Yum-based system: | ||
| - | |||
| - | < | ||
| - | yum install cyrus-sasl-plain | ||
| - | </ | ||
| - | |||
| - | === Local Mail === | ||
| - | |||
| - | Setup Postfix to send local mail to itself. | ||
| - | |||
| - | Tell Postfix where the virtual file is. Add this to ''/ | ||
| - | |||
| - | < | ||
| - | virtual_alias_maps = hash:/ | ||
| - | </ | ||
| - | |||
| - | Add entries in the virtual map file, ''/ | ||
| - | |||
| - | < | ||
| - | root root@localhost | ||
| - | ubuntu ubuntu@localhost | ||
| - | </ | ||
| - | |||
| - | Setup Postfix to use the virtual file: | ||
| - | |||
| - | < | ||
| - | postmap / | ||
| - | </ | ||