Configure Symfony2/Swiftmailer to use “sendmail -t”

前端 未结 3 1063
旧时难觅i
旧时难觅i 2020-12-11 18:45

I\'m currently trying to get Symfony2/Swiftmailer to send the contents of a submitted form via mail. My parameters.yml contains the following:

mailer_transpo         


        
3条回答
  •  [愿得一人]
    2020-12-11 19:34

    This configuration should work.

    mailer_transport: sendmail
    mailer_host: /usr/bin/sendmail # wherever your mail is
    #mailer_user: ~
    #mailer_password: ~
    

    If there is still problem,

    A. check who are sending mail to someone@wxy.com
        1. console - check your permission to access sendmail
        2. web - check web user like wwww-data can access sendmail
    B. check your mail log  /var/log/maillog
        When Symfony Swiftmailer send,
        1. mail log has not been processed, then PHP side problem.
        2. else if: send to outlook
            it is TLS handshake problem, it might be from outlook tls handshake.
            FYI, sendmail TLS is not working with outlook well.
    
            add next line to /etc/mail/access 
            Try_TLS:wxy.com              NO
        3. else:
           Sorry, google with mail log error messages again .
    

提交回复
热议问题