Before today theĀ sendmail command-line tool was disabled on our servers so all apps and scripts had to connect to our SMTP servers to send an email.
As of today sendmail is enabled on all servers which means that any app or script that uses sendmail to send emails will just work without any modification:
[testweb100@web100 ~]$ sendmail support@webfaction.com Subject: Help me Just testing sendmail<ctrl-D> [testweb100@web100 ~]$ <email was sent>
This also means that the native PHP function mail() now works without any extra code:
[testweb100@web100 ~]$ cat testsendmail.php
<?php
$message = "Just testing sendmail\n";
mail('support@webfaction.com', 'Help me', $message);
?>
[testweb100@web100 ~]$ php testsendmail.php
[testweb100@web100 ~]$
<email was sent>
Another place where it can be useful is if you want to receive error emails about failing cronjobs: just add “MAILTO=youremailaddress@yourdomain.com” at the top of your crontab and you’ll start receiving error notifications.
Under the hood the sendmail binary is actually a patched version of msmtp (a sendmail-compatible mail tool) which connects to our SMTP servers to send the email.

Hallelujah! \o/
Rejoice!
Wow! Many thanks.
Hooray!
Thanks!
Excellent news !!!!
WOOT!
Nice, very nice. Are there any plans to re-configure the auto-install for Drupal? As it stands now, the SMTP module is pre-installed to patch the missing sendmail. This ? is for D6 and the now new Drupal 7. thanks much
Ben: The new Drupal-7 one-click installer uses sendmail by default to send emails. No extra config needed
Very nice! I think that’s the only item I had on my list of “things that I have to configure differently for Webfaction from my dev environment”. Kudos!
Pingback: A Look at Our PHP Setup | WebFaction Blog