Hello, I'm trying to setup my rails application to use the latest stable everything, using rvm I was able to get ruby/rails and all that working right. The last step I think is setting up passenger with my existing nginx.

I got far in that I downloaded the src, and ran the configure script pointing to my passenger location. But then I get the error:

Permission denied - /tmp/passenger-compile-check-15512.c.out

In which I'm not sure what to do about that.

The nginx bin files are in my: ~/nginx1.0.5/src/nginx-1.0.5/ folder

which from there I'm supposed to run:

./configure --add-module=/home/pixelfist/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.8/ext/nginx --prefix=/home/pixelfist/webapps/pierce_engineering/nginx2/

The nginx2 is just a test folder since I didn't want to install it over my current nginx installation that was set up for me when I created that app.

asked 05 Aug '11, 20:24

Jaybydesign's gravatar image

accept rate: 50%

Thanks Johns, though as I read through the output of all that I noticed it wasn't nginx that was trying to execute from the /tmp directory. It was actually the rake command to setup the NGINX that was messed up. The problem is the /tmp dir is hard-coded into the ~/.rvm/gems/ruby-1.9.2-p290/gems/passenger-3.0.8/lib/phusion_passenger/platform_info.rb

and on line 163 you see:

   def self.tmpdir
            result = ENV['TMPDIR']

            if result && !result.empty?
                    return result.sub(/\/+\Z/, '')
                    return '/tmp'

So I replaced the line return '/tmp' to return '~/tmp' Then I created a dir: mkdir ~/tmp

So it would work out of the tmp folder in your home directory.

Once I did that and ran that rake command that it was attempting it worked fine, I've also ran the configure script again as well and the phusion-nginx-installer or whatever it was script again and not only did it work, but my site is now fully functional running on the latest stable releases!

permanent link

answered 05 Aug '11, 21:45

Jaybydesign's gravatar image

accept rate: 50%


Wouldn't it be more sensible to just export TMPDIR=$HOME/tmp maybe even in .rvmrc only?

(07 Dec '11, 04:26) Jan Limpens Jan%20Limpens's gravatar image

It looks like it is trying to execute a file within /tmp/ which will not work as /tmp on our servers has noexec for security. Try setting '--builddir' to someplace within your home directory. http://wiki.nginx.org/InstallOptions

permanent link

answered 05 Aug '11, 21:12

johns's gravatar image

johns ♦♦
accept rate: 23%

If you're looking to set up Ruby 1.9.2 with a Passenger + Rails application, see this related community post.

permanent link

answered 06 Jan '12, 19:48

ryans's gravatar image

ryans ♦♦
accept rate: 42%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 05 Aug '11, 20:24

question was seen: 2,547 times

last updated: 06 Jan '12, 19:48

Features & prices    Sign up    Contact us    Affiliate program    Support    Legal    Jobs    Blog    Control panel login
© Copyright 2003-2015 Swarma Limited - WebFaction is a service of Swarma Limited