From aa13200406e1c991d529faefb79cff464848eb95 Mon Sep 17 00:00:00 2001 From: Joshua Parker Date: Thu, 9 Nov 2023 21:26:09 -0700 Subject: [PATCH 1/2] Updated mailer config. --- config/mailer.php | 34 ++++++++++++++++++++++++++++++++-- 1 file changed, 32 insertions(+), 2 deletions(-) diff --git a/config/mailer.php b/config/mailer.php index 520635e..f38e3de 100644 --- a/config/mailer.php +++ b/config/mailer.php @@ -3,11 +3,18 @@ declare(strict_types=1); use function Codefy\Framework\Helpers\env; +use function Codefy\Framework\Helpers\storage_path; return [ /* |-------------------------------------------------------------------------- - | SMTP Swift Mailer Transport + | Default PHPMailer Transport + |-------------------------------------------------------------------------- + */ + 'mail_transport' => 'smtp', + /* + |-------------------------------------------------------------------------- + | SMTP PHPMailer Transport |-------------------------------------------------------------------------- */ 'smtp' => [ @@ -40,6 +47,13 @@ */ 'password' => env(key: 'MAILER_PASSWORD'), + /* + |-------------------------------------------------------------------------- + | Set to true to use SMTP authentication, false otherwise. + |-------------------------------------------------------------------------- + */ + 'auth' => true, + /* |-------------------------------------------------------------------------- | SMTP Auth Mode @@ -68,5 +82,21 @@ |-------------------------------------------------------------------------- */ 'command' => env(key: 'MAILER_SENDMAIL_PATH', default: '/usr/sbin/sendmail -bs'), - ] + ], + + /* + |-------------------------------------------------------------------------- + | Set to true to write to a file for debugging instead of sending + | an actual email. + |-------------------------------------------------------------------------- + */ + 'debug' => false, + + /* + |-------------------------------------------------------------------------- + | .eml file for debugging. Can be opened in email clients such as + | Thunderbird. + |-------------------------------------------------------------------------- + */ + 'emlfile' => storage_path(path: sprintf('email/%s', date(format: 'YmdHis') . '_' . uniqid() . '.eml')), ]; From 90da3882b6234007a919e7ff028001ec0430bca8 Mon Sep 17 00:00:00 2001 From: Joshua Parker Date: Thu, 9 Nov 2023 21:26:34 -0700 Subject: [PATCH 2/2] Added email directory. --- storage/email/.gitkeep | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 storage/email/.gitkeep diff --git a/storage/email/.gitkeep b/storage/email/.gitkeep new file mode 100644 index 0000000..e69de29