我正在尝试使用Migadu作为我的服务器的电子邮件主机,但是当我使用sendmail测试postfix时,我收到错误
550 From标头与登录用户不匹配
我在main.cf中有这些设置
relayhost = [smtp.migadu.com]:587
smtpd_sasl_auth_enable = yes
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options =
smtpd_tls_security_level = encrypt
smtp_use_tls = yes
smtp_tls_CAfile = /etc/ssl/certs/ca-certificates.crt
我在我的sasl_passwd文件中有这个
[smtp.migadu.com]:587 [email protected]:password
有人可以帮我找出导致错误的原因吗?
对于仍在寻找的人来说,想出来了......
在Laravel的mail.php配置文件中,找到有关全局“发件人”地址的部分。
/*
|--------------------------------------------------------------------------
| Global "From" Address
|--------------------------------------------------------------------------
|
| You may wish for all e-mails sent by your application to be sent from
| the same address. Here, you may specify a name and address that is
| used globally for all e-mails that are sent by your application.
|
*/
'from' => [
'address' => env('MAIL_FROM_ADDRESS', '[email protected]'),
'name' => env('MAIL_FROM_NAME', 'Example'),
],
您必须将[email protected]更改为您的migadu电子邮件登录名。之后它对我有用。