title: Rails action mailer didn't work on production
body: <p>I am trying to send emails via action mailer. I have the same config for production and for development:</p>
  
  <pre><code>config.action_mailer.delivery_method = :smtp
  config.action_mailer.smtp_settings = {
      address:              'ee.ex.my_domain.net',
      port:                 465,
      domain:               'my_domain',
      user_name:            'email@my_mail.com',
      password:             'my_pass',
      authentication:       :ntlm,
      enable_starttls_auto: true
  }
  
  config.action_mailer.default_url_options = { :host =&gt; "localhost:3000" }
  </code></pre>
  
  <p>The only difference between development and production config is the host. For production I use an existing url, on my local machine it works ok but when I try it on the server I got this error:</p>
  
  <pre><code>Net::SMTPSyntaxError (504 5.7.4 Unrecognized authentication type)
  </code></pre>
  
  <p>I have had this error before on my local machine but I changed the authentication to <code>:ntml</code> and it works fine.</p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>tried in server console (code from ntlm gem github page)</p>
  
  <pre><code>require 'ntlm/smtp'
  smtp = Net::SMTP.new('smtp.example.com')
  smtp.start('localhost.localdomain', 'Domain\\User', 'Password', :ntlm) do |smtp|
    smtp.send_mail(mail_body, from_addr, to_addr)
  end
  </code></pre>
  
  <p>but have the same error </p>