Monday, February 3, 2014

Install SSMTP in OpenWRT

opkg install ssmtp
$ cat /etc/ssmtp/ssmtp.conf
root=xx@gmail.com
mailhub=smtp.gmail.com:465  
rewriteDomain=gmail.com  
hostname=gmail.com  
FromLineOverride=YES  
UseTLS=YES
AuthUser=xx  
AuthPass=PASSWORDHERE

$ echo -e "From: MYEMAIL@MYDOMAIN.COM\nSubject: SUBJECT\nReply-to: MYEMAIL@MYDOMAIN.COM\n\nBODYHERE" | ssmtp -vvv MYOTHEREMAIL@MYDOMAIN.COM

No comments:

Post a Comment