Forums before death by AOL, social media and spammers... "We can't have nice things"
|    alt.os.linux.slackware    |    I think its the one without Selinux crap    |    87,272 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 86,061 of 87,272    |
|    Harold Johanssen to Harold Johanssen    |
|    Re: Sending mail without having to use s    |
|    17 Nov 22 16:22:43    |
      From: noemail@please.net              On Thu, 17 Nov 2022 15:53:57 -0000 (UTC), Harold Johanssen wrote:              > I have a system running 15.0 with Internet access. Every so often this       > system must send terse email notifications, as invoked from a cron job.       > It is not going to receive any emails.       >       > Any suggestions on how to do this without having to get sendmail       > configured and running? This would amount to using an email client that       > does not require a local sendmail, like e.g. Thunderbird. This is of       > course not a an option: I need something that is command-line oriented       > and lightweight.               Well, as it turns out to be the case spookily often, I figured it       out minutes after I posted this. In case anybody might be interested:               I created a file named .mailrc in the home directory for the user       who is going to be sending the emails, with the following contents in       this file:              # Testing syntax:       # echo "Testing, Testing, Testing" | mailx -s "My test..."       # address@whatever.com              # Use v15.0 compatibility mode       set v15-compat              # See the whole process, especially for troubleshooting:       set verbose              # Essential setting: select allowed character sets       set sendcharsets=utf-8,iso-8859-1       # and reply in the same charset used by sender:       set reply-in-same-charset              # Default directory where we act in (relative to $HOME)       set folder=mail              # You actual address to reply to:       set from="myname@myaddress.com"              # Request strict TLS transport layer security checks              # set tls-verify=strict       # set tls-ca-file=/etc/ssl/certs/ca-certificates.crt       # set tls-ca-no-defaults              # Alternative, don't do SMTP server certificate verification              set tls-verify=ignore       set smtp-use-starttls       set smtp-auth=login              # When sending messages, wait until the Mail-Transfer-Agent finishes.       # Only like this you will be able to see errors reported through the       # exit status of the MTA (including the built-in SMTP one)!       set sendwait              # And of course put your own username and password here in the obvious       # places:              set mta=smtps://USERNAME:PASSWORD@SMTP.SERVER:465                      With this, a simple invocation as mentioned at the top of the       file sends the email as expected. In my case, I disable TLS security       checks because I know what the SMTP server that will be connecting to is,       and that's the only server that I will be using here. All this suffices       to fulfill my needs.              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca