Problem with environmental variables and FastCGI

Hi,

I’m trying to deploy my app using FastCGI, and I have a problem. The
application
works correctly in either FastCGI or CGI mode (toggling between
dispatch.fcgi and
dispatch.cgi in my public/.htaccess file) except that under regular CGI,
my
ENV hash is correctly set, but under FastCGI, the ENV hash is completely
empty. I
thought that environment variables were automatically passed to the
FastCGI
app
as if it was a regular CGI application.

Can someone help?

Thanks,

Stan McFarland

View this message in context:
http://www.nabble.com/problem-with-environmental-variables-and-FastCGI-t1506204.html#a4084539
Sent from the RubyOnRails Users forum at Nabble.com.

More info:

I can access the environmental variables from the controller or the view
by
using @request.env - this has the environment populated successfully.
Here’s my problem, though. I need to be able to access the environment
from
a method in a model, and @request is not defined in the model. As I
said
earlier, ENV is defined via CGI, which I can refer to in the model,
but
it’s not defined if I use FastCGI.

Any suggestions? I’m desperate. :wink:

View this message in context:
http://www.nabble.com/problem-with-environmental-variables-and-FastCGI-t1506204.html#a4091567
Sent from the RubyOnRails Users forum at Nabble.com.