Skip to content

Instantly share code, notes, and snippets.

@mkurz
Forked from rafi/install.sh
Created Jun 5, 2018
Embed
What would you like to do?
setup msmtp and php
apt-get install msmtp ca-certificates
vim /etc/msmtprc
# Set defaults.
defaults
# Enable or disable TLS/SSL encryption.
tls on
tls_starttls on
tls_trust_file /etc/ssl/certs/ca-certificates.crt
# Set up a default account's settings.
account default
host smtp.sendgrid.net
port 587
auth on
user <username>
password <password>
from bounces@your-doman-here
logfile /var/log/msmtp/msmtp.log
vim /etc/php5/apache2/php.ini
sendmail_path = /usr/bin/msmtp -t
mkdir /var/log/msmtp
chown www-data:adm /var/log/msmtp
vim /etc/logrotate.d/msmtp
/var/log/msmtp/*.log {
rotate 12
monthly
compress
missingok
notifempty
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment