On 2 Oct 2003, at 10:34 pm, Ian Truelsen wrote:
I am trying to find some documentation for ssmtp. I want to write a
script that would send mail to root in the event of a password failure
and, eventually, other things too. However, when I use the ssmtp root
command, it allows me to type in, what I would imagine is the text of
the message, but I can't figure out how to exit out of that and send the
message. Also, I would need to automate the process.
Anyone know where the documentation is for this?
From `man ssmtp`: ssmtp is a send-only sendmail emulator...
It accepts a mail stream on *STANDARD INPUT* with recipients
specified on the command line and synchronously forwards
the message to the mail transfer agent of a mailhub for
the mailhub MTA to process. Failed mes- sages are placed in
dead.letter in the sender's home directory.The emphasis on *STANDARD INPUT* is mine. It means that you can use commands of the format:
$ cat wibble | /usr/sbin/ssmtp [EMAIL PROTECTED]
and for debugging:
$ cat wibble | /usr/sbin/ssmtp -v [EMAIL PROTECTED]
I suggest using the latter until you have successfully configured /etc/ssmtp/ssmtp.conf, which i found took about 3 changes to get working.
HTH,
Stroller.
-- [EMAIL PROTECTED] mailing list
