There’s a number of CPAN modules related to sending email for Perl, several of which Dreamhost already has pre-installed. You can use one of the SMTP-related ones and have it authenticate and connect to your normal mail server for outgoing. Dreamhost also appears to have postfix on the web servers, and the command-line submission tool for that is at /usr/lib/sendmail. Generally if you run “/usr/lib/sendmail -ti” and then paste in an email (headers and all) it’ll take the To and From out of the headers and send it. So that’s the quick and dirty way is just open a pipe filehandle to sendmail and print your email to it.
print MAIL <<“EOF”;
This is the body of the message.
note the @ inside the << structure has a \ in front of it because it’s a literal @ and not the marker for an array variable.