Prepare proper phpmail config for FreeBSD.

This commit is contained in:
Retro_Guy 2024-12-01 16:42:22 -07:00
parent e19661f9bd
commit 616cc09975
3 changed files with 33 additions and 0 deletions

View File

@ -86,6 +86,7 @@ cp -a rocksolid $webroot
cp -a spoolnews $webroot
cp -a rslight/* $configpath
cp rslight/fortunes.conf.bsd $configpath/fortunes.conf
cp rslight/phpmailer.inc.php.bsd $configpath/phpmailer.inc.php
echo "done"
echo
echo -n "Setting permissions..."

View File

@ -91,6 +91,7 @@ cp rslight/*.php $configpath/upgrade
cp rslight/*.conf $configpath/upgrade
cp rslight/*.dist $configpath/upgrade
cp rslight/fortunes.conf.bsd $configpath/upgrade/fortunes.conf
cp rslight/phpmailer.inc.php.bsd $configpath/upgrades/phpmailer.inc.php
echo "done"
echo
echo -n "Setting permissions..."

View File

@ -0,0 +1,31 @@
<?php
# Server info and credentials for sending email
# (sending mail requires PHPMailer package installed)
$phpmailer['phpmailer'] = '/usr/local/share/phpmailer/class.phpmailer.php';
$phpmailer['smtp'] = '/usr/local/share/phpmailer/class.smtp.php';
# Custom Headers (you can add multiple)
#$mail_custom_header['X-Custom-Header-Name'] = "header info";
# Admin address info
# This will format email address as:
# $mail_admin_user@$mail_admin_domain
$mail_admin_user = "adminuser";
$mail_admin_domain = "admindomain";
$mail_admin_name = "Name for Admin";
# Display From info
$mail_user = "user";
$mail_domain = "domain";
$mail_name = "Name for user";
# Log in info
$mailer = array();
$mailer['host'] = "mail.example.com";
$mailer['port'] = "587";
$mailer['username'] = "username";
$mailer['password'] = "password";
require $phpmailer['phpmailer'];
require $phpmailer['smtp'];