1

i have a problem with my prod actionmailer. I'm hosted on site5 sharing cloud. The problem is i get this error message.

A message that you sent using the -t command line option contained no
addresses that were not also on the command line, and were therefore
suppressed. This left no recipient addresses, and so no delivery could
be attempted.

------ This is a copy of your message, including all the headers. ------

Date: Sat, 17 Sep 2011 21:06:42 +0000
From: [email protected]
To: [email protected]
Message-ID: <[email protected]>
Subject: test
Mime-Version: 1.0
Content-Type: text/plain;
charset=UTF-8
Content-Transfer-Encoding: 7bit

i added default

default :recipient => '[email protected]'

but the mail return me the same error.

my ActionMailer controller

class Emailtousers < ActionMailer::Base
  default :from => "[email protected]"
  default :recipient => "[email protected]"
  def plan_notification(resource)
    @resource = resource
    puts resource
    mail(:to => "[email protected]", :subject => 'test')
  end
end

What i missed?

i followed this to help me http://edgeguides.rubyonrails.org/action_mailer_basics.html

4
  • please try it with a recipient that is outside that domain and let us know what you get
    – jschorr
    Commented Sep 18, 2011 at 7:06
  • The Recipient are the to: mail? i've tried with another domain and another email, and the default from get the same mail.. no recipient messages. Thanks
    – neimad
    Commented Sep 18, 2011 at 14:26
  • Yes, recipients are the ones that get the email.
    – jschorr
    Commented Sep 18, 2011 at 20:01
  • ok, i get the same thing! My host told me to change authentication => :login to :plain, but same thing!
    – neimad
    Commented Sep 18, 2011 at 23:28

1 Answer 1

6

I got this problem using the :sendmail delivery method with exim. Adding this to config/application.rb fixed it for me:

config.action_mailer.sendmail_settings = { :arguments => "-i" }

I found the solution at https://github.com/mikel/mail/issues/70#issuecomment-2639987

3
  • thanks, i resolved this issue .. the problem was on server side. not properly mail setting. But thanks for this fix. i will try it with my next rails projets.
    – neimad
    Commented Jul 24, 2012 at 19:17
  • @neimad could you please share the solution you found for this issue?
    – Robin
    Commented Nov 12, 2013 at 10:28
  • @neimad: yes, please, as Robin said... I could also only work this around with Steve's solution, and feel quite puzzled why.
    – Sz.
    Commented May 8, 2014 at 2:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.