avatar
install and configure SSMTP on Ubuntu to send email via command line Linux

• Install ssmtp with the following commands:

sudo apt-get update
sudo apt-get install ssmtp

• Open file ssmtp.conf and re-adjust

sudo nano /etc/ssmtp/ssmtp.conf

Notice: That means email is sent from [email protected] and password to authorize. Your information recipient will show in command send.

[email protected]
mailhub=smtp.gmail.com:465
FromLineOverride=YES
[email protected]
AuthPass=Abc@112233
UseTLS=YES

• Testing by carrying out of sending email [email protected]

echo "Hello world" | ssmtp [email protected]
or printf "Subject: Programming Linux\n\nTesting ...1...2...3" | ssmtp [email protected]

In some cases, let enable fewer security applications from link.

24
send mail via share hosting setup Gmail IMAP and SMTP settings for email clients
You need to login to do this manipulation!