Table of Contents

Mail

You can use Synchronet as your native UNIX mail system so that UNIX system components (e.g. crond, apt, security) will send e-mail notifications to the system administrator (you) as user #1 on your BBS using your Synchronet mail system.

Install

Create the following symbolic links to the Synchronet sendmail script:

$ ls -l /usr/sbin/*mail
lrwxrwxrwx 1 root root    26 Mar  5 23:03 /usr/sbin/sendmail -> /sbbs/exec/sendmail.js
$ ls -l /usr/bin/mail*
lrwxrwxrwx 1 root root    37 Feb 13 15:44 /usr/bin/mail -> /sbbs/exec/sendmail.js
lrwxrwxrwx 1 root root    37 Feb 13 15:44 /usr/bin/mailx -> /sbbs/exec/sendmail.js

Linux

These symlinks may be installed automatically (and double-redirected via /etc/alternatives/* symlinks) using the Linux update-alternatives utility:

$ sudo update-alternatives --install /usr/bin/mailx mailx /sbbs/exec/sendmail.js 100 --slave /usr/bin/mail mail /sbbs/exec/sendmail.js --slave /usr/sbin/sendmail sendmail /sbbs/exec/sendmail.js

The Synchronet sendmail script contains a “shebang” that will invoke exec/jsexec to execute sendmail.js. In turn, sendmail.js will determine its personality (e.g. which command-line arguments it will recognize: sendmail or mail/mailx) based on which symlink was used to invoke it.

See Also