什么是:配置动作邮件时引用的域符号?

Spe*_*ley 9 ruby gmail ruby-on-rails actionmailer

Appname::Application.configure do 

config.action_mailer.delivery_method = :smtp
#typical smtp_settings for gmail account
config.action_mailer.smtp_settings = {
  :address => "smtp.gmail.com",
  :port => 587,
  :domain => "domain.of.sender.net",
  :authentication => "plain"
  :user_name => "spencecooley"
  :password => "secret"
  :enable_starttls_auto => true
}

end
Run Code Online (Sandbox Code Playgroud)

我有两个关于配置动作邮件的问题

  1. 你知道:域名符号是指什么吗?它是在谈论应用程序的域名吗?它是在谈论邮件服务器域吗?我看到baci.lindsaar.net写在我用Google搜索的一些网站上,但我不知道为什么人们使用那个特定的域名.项目清单
  2. 我也不知道自己在:enable_starttls_auto => true做什么

更新:

好的,所以我在参考问题2的文档中找到了这个

:enable_starttls_auto - 设置为true时,检测SMTP服务器中是否启用了STARTTLS并开始使用它

不知道STARTTLS是什么,所以我在这里了一下http://en.wikipedia.org/wiki/STARTTLS

更新:我在文档中发现了这个,但仍然不明白

:domain - 如果您需要指定HELO域,可以在此处执行.

所以我猜新问题是:什么是HELO域名?似乎无法找到明确的答案.

Rya*_*igg 9

:domain键被设置了HELO检查.如果您使用的是GMail,则无需指定此项.

STARTTLS呼叫启动与您的邮件服务器的加密连接,这需要使用GMail的SMTP.