現在、本番環境でActionMailerによるメールの設定を行なっているのですが、以下のようなエラーが発生しており、詰まっております。
使用しているのはパスワード再設定時のメール送信時に使っております。
SocketError (getaddrinfo: Name or service not known)
エラー内容は名前またはサービスをrails側が認識していないエラーだと思っております。
production
1 config.action_mailer.default_url_options = { host: 'ドメイン名' } 2 config.action_mailer.delivery_method = :smtp 3 config.action_mailer.smtp_settings = { 4 address:"smtp@gmail.com", 5 domain: 'gmail.com', 6 port:587, 7 user_name: ENV['GMAIL_NAME'].to_s, 8 password: ENV['GMAIL_PASSWORD'].to_s, 9 authentication: 'plain', 10 enable_starttls_auto: true 11} 12
よろしくお願いします。
あなたの回答
tips
プレビュー