I would try testing just smtp delivery and make sure that is working, before adding the extra layer of complexity. Right now it's not clear whether the message is being rejected by postfix, or postfix is misconfigured, or rails is misconfigured.

A peek at the relevant sections, if any, in /var/log/mail.log would be helpful -

Joe

Tashfeen Ekram wrote:
I installed it with apt-get install postfix and then choose "Internet Site" during the configuration. i have configured rails to use smtp.
config.action_mailer.smtp_settings = {
  :address        => 'localhost',
  :port           => 25,
  :domain         => 'www.example.com',
}

here is the trace i get:

Timeout::Error (execution expired):
  /usr/lib/ruby/1.8/timeout.rb:60:in `open'
  /usr/lib/ruby/1.8/net/smtp.rb:551:in `do_start'
  /usr/lib/ruby/1.8/net/smtp.rb:551:in `do_start'
  /usr/lib/ruby/1.8/net/smtp.rb:525:in `start'
  app/controllers/user/dashboard_controller.rb:13:in `index'

Rendered rescues/_trace (82.7ms)
Rendered rescues/_request_and_response (0.7ms)
Rendering rescues/layout (internal_server_error)




----- Original Message ----
From: J Sloan <j...@tmsusa.com>
To: postfix-users@postfix.org
Sent: Monday, April 13, 2009 5:45:40 PM
Subject: Re: Newbie configuration/installation question

Tashfeen Ekram wrote:
I have installed Postfix on Ubuntu to use to only send emails for my
rails application. My rails application is not able to connect to it.
Could this be because sendmail is listeneing at port 20?
also, what configuration would suit me best if I only want to send
emails ant not receive. This is onyl for testing purposes on my own
laptop.


Just to eliminate a lot of guesswork: when you say you "installed
postfix" did you do something like "apt-get install postfix" or click on
postfix to install via synaptic, or did you download a tarball from the
internet and build it yourself?

How is rails configured to send the mail - with the sendmail command, or
via an smtp connection to the local host?

Joe




Reply via email to