-1

so here's the whole text i'm sending:

enter image description here

and here's the email i'm receiving:

enter image description here

basically i just cat the file and echo then pipe it to ssmtp like this:

result=`cat file.out` 
echo "$result" | ssmtp $emailaddr
jeremybcenteno
  • 119
  • 4
  • 15
  • 1
    https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_transport_example basically, add an empty line in front of all lines. – KamilCuk Aug 11 '20 at 08:18

1 Answers1

1

ssmtp protocol defines the lines in format something: something to be the header lines, like From: some@email.com defines where from the email is. So if you want to specify the body only, add a leading empty line as the separator between the header and body of the message and hopefully ssmtp should pick it up.

KamilCuk
  • 120,984
  • 8
  • 59
  • 111