thank you all for your answers, for sure there is more than one way, have to further investigate all links provided here
2014-11-19 16:24 GMT+02:00 Cory Snavely <[email protected]>: > I've always used this: > > http://search.cpan.org/~markov/MailTools-2.13/lib/Mail/Mailer.pod > > On 11/19/2014 09:22 AM, Sergio Letuche wrote: > >> ok this is what i asked, could a mail be sent without mailx been >> installed, >> >> thank you >> >> 2014-11-19 16:19 GMT+02:00 PHILLIPS M.E. <[email protected] >> <mailto:[email protected]>>: >> >> Not sure exactly what you mean by not using a mailer.____ >> >> __ __ >> >> In our Perl scripts I tend to do:____ >> >> __ __ >> >> open (MAIL, "|-", '/bin/mailx', '-s', $subject, @addresses)____ >> >> || die "Failed to e-mail report: $!\n";____ >> >> print MAIL $report;____ >> >> close MAIL;____ >> >> __ __ >> >> which relies on mailx being installed and able to send messages.____ >> >> __ __ >> >> I’m sure there are SMTP modules for Perl, and things like that which >> could do it all at socket level, but I wouldn’t see that as being >> easier necessarily. It depends on what control you have over your >> server.____ >> >> __ __ >> >> Matthew____ >> >> __ __ >> >> *From:*Sergio Letuche [mailto:[email protected] >> <mailto:[email protected]>] >> *Sent:* 19 November 2014 08:31 >> *To:* [email protected] <mailto:[email protected]> >> *Subject:* send emails via perl____ >> >> __ __ >> >> hello,____ >> >> __ __ >> >> we need to use the easiest solution, if possible just use a perl >> module, to be able to send automated emails on an Ubuntu server. The >> scenario is this: we ran a cron job, and say we would like to send a >> message after completion, to a certain for example gmail account. >> The ideal would be to not use any mailer, is this possible? Or could >> you please suggest us the best - easiest approach?____ >> >> __ __ >> >> Thank you____ >> >> >>
