OpenSSL::SSL::SSLError (hostname "" does not match the server certificate)

When I deployed my rails app with cent os6 while sending email it is
me 'OpenSSL::SSL::SSLError (hostname “” does not match the
server certificate) ,

This is my mailer settings
config.action_mailer.smtp_settings = {
address: ‘’,
port: 587,
domain: ENV[‘DOMAIN_NAME’],
authentication: ‘plain’,
enable_starttls_auto: true,
user_name: ENV[‘GMAIL_USERNAME’],
password: ENV[‘GMAIL_PASSWORD’],
openssl_verify_mode: ‘none’

Let me know if any one can help . Thanks in advance.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs