ok, so you have a default postfix install and one piece of r0r app that must be configured to send emails.
I will assume you will install postfix on the same server you are running your ror application. If you are planning to host the postfix install on a remote server, don't. I advise on using a local postfix installation as described below, mostly for security purposes.
to make sure you installed postfix correctly do a fresh postfix install IF and only if you are ok with completely deleting the current postfix installation. If you're not ok with this just skip to __postfix_configuration_checks paragraph.
apt-get purge postfix
apt-get install postfix
On debian (and I guess on ubuntu as well) the installer will ask you how do you want to use postfix. choose "local only". That is, "the only delivered mail is the mail for local users", just as a security measure.
when the install process finishes you should have a postfix instance listening on localhost, port 25, allowing mail sent from localhost to be queued unconditionally (default settings)
__postfix_configuration_checks
you can check the policies by running postconf like this:
postconf smtpd_recipient_restrictions mynetworks
and the output you will see should be the same with:
smtpd_recipient_restrictions = permit_mynetworks, reject_unauth_destination
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
you should also (double-) check that your postfix is listening only on loopback interface, port 25:
netstat -nltp |grep master
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 4713/master
now you're ready to configure your rail app:
hostname='localhost' #or '127.0.0.1'
port=25
password='' #or nil, dunno
username='' #or nil?
you should be able to send emails from your ror app thru your postfix install