Laravel Mail to Log

I have a Laravel Mail driver setup to print to a log file:

'driver' => env('MAIL_DRIVER', 'log'),

When sending mail, however, I get a swiftmail authentication error:

The expected response code is 250, but received the code "530" with the message "530 5.7.1 Authentication Required

vendor\\swiftmailer\\swiftmailer\\lib\\classes\\Swift\\Transport\\AbstractSmtpTransport.php

line 383 \ "> AbstractSmtpTransport.php line 383

530 5.7.1 Authentication required

Is there any other parameter that I need to set? Why is he trying to use swiftmailer?

+13
source share
5 answers

This is the configuration file Mail.php ...

Using

'driver' => env('MAIL_DRIVER', 'log'),

MAIL_DRIVER .ENV . "log" , .ENV ... , .env ... ...

MAIL_DRIVER=smtp

MAIL_DRIVER=log
+23

Laravel .ENV !

, edit config\mail.php, ENV

dd(config('mail'));

, .

0

?

0

- L5.8 "log" env.

Swift_TransportException (530) The expected response code is 250, but received the code "530" with the message "530 5.7.1 Authentication Required"

You need to restart the web server and restart php artisan serve.

0
source

Another reason your configuration MAIL_DRIVER=logmay not work as expected is QUEUE_DRIVERbecause something different is set for yours sync.

Thanks to a tip from Gibex at Laracasts .

0
source

Source: https://habr.com/ru/post/1672307/


All Articles