当收件人邮箱是 Gmail 腾讯企业邮箱 QQ 邮箱等都可以正常发送和接收,但是当收件人邮箱是 163 邮箱时,就会接收不到邮件,这是为何呢?163 有毒啊??!! 配置如下:
# config/environments/development.rb
config.action_mailer.perform_caching = false
config.action_mailer.perform_deliveries = true
config.action_mailer.raise_delivery_errors = true
config.action_mailer.delivery_method = :smtp
config.action_mailer.smtp_settings = {
address: 'smtp.exmail.qq.com',
port: 465,
domail: 'qq.com',
ssl: true,
user_name: 'username',
password: 'password',
authentication: 'plain',
enable_starttls_auto: true,
}