配置 mail.rb 进行本地主机测试

发布于 2024-08-19 05:59:48 字数 522 浏览 2 评论 0原文

是否可以配置mail.rb(在RESTFUL身份验证中)来本地测试电子邮件激活?默认文件是

ActionMailer::Base.delivery_method = :smtp
ActionMailer::Base.smtp_settings = {
    :address => "mail.example-domain.com",
    :port => 25,
    :domain => "www.example-domain.com",
    :authentication => :login,
    :user_name => "[email protected]",
    :password => "secret"
}

thanks

is it possible to configure mail.rb (in RESTFUL authentication) to test email activation locally? the default file is

ActionMailer::Base.delivery_method = :smtp
ActionMailer::Base.smtp_settings = {
    :address => "mail.example-domain.com",
    :port => 25,
    :domain => "www.example-domain.com",
    :authentication => :login,
    :user_name => "[email protected]",
    :password => "secret"
}

thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

北音执念 2024-08-26 05:59:48

这可能会有所帮助:

只需制作一个包含所有配置的 yaml 文件

This might help:

Just make a yaml file with all the config

思慕 2024-08-26 05:59:48

我真的很喜欢使用 MailTrap —— 一个本地 SMTP 服务器,它了解 SMTP 足以侦听 ActionMailer请求...并将它们写入一个文件,您可以稍后查看它们。

I really like using MailTrap -- a local SMTP server that knows Just Enough about SMTP to listen to ActionMailer requests... and write them to a file where you can look at them later.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文