These are my mail settings:

config.action_mailer.delivery_method = :sendmail
config.action_mailer.raise_delivery_errors = true

# Enable serving of images, stylesheets, and javascripts from an asset
server
# config.action_controller.asset_host                  = "http://
assets.example.com"

config.action_mailer.sendmail_settings = {
 :location        => '/usr/sbin/sendmail',
 :address         => 'mail.mydomain.com',
 :port            => 25,
 :domain          => 'www.mydomain.com',
 :arguments      => '-i -t'

Check your production log after sending an email (you can do this
easily by tailing the log in one console and running the rails console
in another with the command "RAILS_ENV=production ruby script/
console")

Then just type in your ruby command to send an email and see what your
production log says.

I had an issue where my emails were not being sent due to strict
policies with AOL.  I debugged the issue using a tcp dump and tpick (i
am on ubuntu).

to capture:
tcpdump -s 0 -i eth0 -w tcp_dump.pcap tcp port 25

...assuming you are using port 25...then send your email and read the
pcap dump with

tcpick -C -yP -r tcp_dump.pcap

I am a bit of noob with debugging email but I did spend a couple days
doing it.  Hope this helps.

On Oct 5, 4:34 am, Andi Schacke <andreas.scha...@gmail.com> wrote:
> If you're still wondering why mails get sent in development mode: You
> probably have sendmail installed on your development machine, it just
> works out of the box. If you don't want to send mails in development
> mode, just set 'perform_deliveries = false' in your action_mailer
> configuration for your development environment.
>
> Andi
>
> On Oct 4, 4:27 pm, Sender <iloveguit...@gmail.com> wrote:
>
> > Hi Adam,
>
> > You need to first figure out your mail settings in environment.rb.
> > Please see for those settings in action mailer API.
>
> > Hope it works for you, because there can be many reasons for this issue.
>
> > On Sun, Oct 4, 2009 at 4:21 PM, Adam Meyer
>
> > <rails-mailing-l...@andreas-s.net> wrote:
>
> > > Hey everyone
>
> > > I put my developed app first time in production mode. Now I see that the
> > > Mails are not sent by the app. The strange think is, that it already
> > > sent mails in development environment. But only sometimes.
>
> > > How can I debug the mail sending by actionmailer? I have no idea where
> > > to start.
>
> > > Thanks in advance...
>
> > > Adam
> > > --
> > > Posted viahttp://www.ruby-forum.com/.
>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to