配置.yml
development:
email_delivery:
delivery_method: :smtp
smtp_settings:
#tls: true
#enable_starttls_auto: true
openssl_verify_mode: 'none'
address: "domain name"
port: 25
authentication: :login
domain: 'mail domail name'
user_name: 'mail id'
password: 'pwd'
此代码用于发生以下错误
发送邮件时出错:
SSL_connect returned=1 errno=0 state=SSLv2/v3 read server hello A: unknown protocol
development:
email_delivery:
delivery_method: :smtp
smtp_settings:
tls: true
enable_starttls_auto: true
openssl_verify_mode: 'none'
address: "domain name"
port: 587
authentication: :login
domain: 'mail domail name'
user_name: 'mail id'
password: 'pwd'
此代码用于发生以下错误
发送邮件时出错:
No connection could be made because the target machine actively refused it. - connect(2)
development:
email_delivery:
delivery_method: :async_smtp
smtp_settings:
tls: true
enable_starttls_auto: true
openssl_verify_mode: 'none'
address: "domain name"
port: 25
authentication: :login
domain: 'mail domail name'
user_name: 'mail id'
password: 'pwd'
没有发生错误但仍然没有收到用户的邮件。
development:
email_delivery:
delivery_method: :smtp
smtp_settings:
tls: true
enable_starttls_auto: true
openssl_verify_mode: 'none'
address: "domain name"
port: 25
authentication: :login
domain: 'mail domail name'
user_name: 'mail id'
password: 'pwd'
此代码使用 redmine 版本 2.2.3 可以正常使用。但现在使用的 2.3.0 版无法正常工作。