Ruby Forum Ruby on Rails > Actionmailer environment

Posted by Eric Mills (snowbird122)
on 11.05.2008 18:45
I'm trying to receive emails into my rails app.  The using this method:
http://wiki.rubyonrails.org/rails/pages/HowToReceiveEmailsWithActionMailer

It appears to be passing the email in using the development environment
instead of production.  How can I make it use production?  The rest of
my app is using production as specified in my mongrel configuration.
Posted by Frederick Cheung (Guest)
on 11.05.2008 20:17
(Received via mailing list)
On 11 May 2008, at 17:45, Eric Mills wrote:

>
> I'm trying to receive emails into my rails app.  The using this  
> method:
> http://wiki.rubyonrails.org/rails/pages/HowToReceiveEmailsWithActionMailer
>
> It appears to be passing the email in using the development  
> environment
> instead of production.  How can I make it use production?  The rest of
> my app is using production as specified in my mongrel configuration.

script/runner takes a -e option which specifies the environment to use.

Fred

--
My ramblings: http://www.spacevatican.org
Posted by Eric Mills (snowbird122)
on 11.05.2008 21:48
Worked great, thanks.

Here is the syntax from my /etc/aliases file:
email_alias: "| /usr/bin/ruby /path/to/app/script/runner -e production 
'IncomingMailProductRequest.receive STDIN.read'"