2015-04-02 55 views
0

我可以在本地网络应用程序中以管理员身份登录,但是当我到Heroku登录时,说我需要确认发送到我的收件箱的电子邮件。问题是,当我要求它重新发送时,我永远不会收到发送到我的收件箱的电子邮件。在我的Heroku制作应用程序中,我无法登录

所以现在我无法登录。

这里是我的Heroku应用 https://chip-reddit.herokuapp.com

链接这里是我的github上的链接。 https://github.com/goldmullet/bloccit

任何想法为什么?

+0

联系SendGrid的支持,我也怀疑这是垃圾邮件。您应该知道,通过SendGrid创建的免费SendGrid帐户具有比通过heroku获得的更多功能。 – 2015-04-02 22:28:57

回答

3

问题可能出在邮件提供者身上。根据我的经验,SendGrid经常需要通过他们的网站支持联系人工干预,以允许Heroku应用程序发送电子邮件。我相信这是一种反垃圾邮件措施。

作为临时解决方法(可能在等待SendGrid响应时),您可以通过rails控制台手动确认用户。在终端:

heroku run rails c 

# ... 
# Wait a few seconds for rails console to open 
# ... 

# Get admin user out of the db and mark as confirmed 
admin = User.find_by(email: "[email protected]") 
admin.skip_confirmation! 
admin.save! 

# Exit the console 
exit 
相关问题