Heroku not sending email with Gmail SMTP

后端 未结 3 1413
既然无缘
既然无缘 2020-12-04 02:45

The app works everything, I\'m trying to use Confirmable with Devise, on my Rails app it says that the email was sent, but I never receive it. I\'m configuring it with Gmail

3条回答
  •  醉酒成梦
    2020-12-04 03:33

    You have to check two important things when you want to send emails via Gmail smtp:

    1. Your apps configuration:

      • host: smtp.gmail.com
      • port: 587 or 465 (587 for tls, 465 for ssl)
      • protocol: tls or ssl
      • user: YOUR_USERNAME@gmail.com
      • password: YOUR_PASSWORD
    2. The given Gmail account settings:

      • If you've turned on 2-Step Verification for your account, you might need to enter an App password.
      • Without 2-Step Verification:
        1. Allow less secure apps access to your account.
        2. Visit http://www.google.com/accounts/DisplayUnlockCaptcha and sign in with your Gmail username and password.

提交回复
热议问题