2

So i'm trying to get ssmtp with mailutils running for unattended upgrades, but it won't work. I was following this guide: https://raspberry-projects.com/pi/software_utilities/email/ssmtp-to-send-emails But it didn't work so i edited the revaliases and tried other things but nothing works...

This is my /etc/ssmtp/ssmtp.conf:

root=postmaster
mailhub=smtp.gmail.com:587
hostname=raspberrypi
FromLineOverride=YES
AuthUser=test1.test2@gmail.com
AuthPass=******
UseTLS=YES
UseSTARTTLS=YES

My /etc/ssmtp/revaliases looks like this:

root:test1.test2@gmail.com:smtp.gmail.com:587

I already tried activating less secure apps in my google account.

This is always the result:

echo "Hello world email body" | mail -s "Test Subject" me.me@gmail.com
mail: cannot send message: Process exited with a non-zero status

I also tried with a msg.txt and only ssmtp:

ssmtp me.me@gmail.com < msg.txt
ssmtp:  (raspberrypi)

but nothing would be there.

frieren
  • 55
  • 1
  • 4

1 Answers1

1

ssmtp has been deprecated in Buster

In general following ANY 5 year old post is at best an exercise in optimism
See https://raspberrypi.stackexchange.com/a/100704/8697

Milliways
  • 62,573
  • 32
  • 113
  • 225