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

Jaybydesign
2616
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/, '')
            else
                    return '/tmp'
            end
    end

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!

link

answered 05 Aug '11, 21:45

Jaybydesign's gravatar image

Jaybydesign
2616
accept rate: 50%

1

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

link

answered 05 Aug '11, 21:12

johns's gravatar image

johns ♦♦
4.1k28
accept rate: 23%

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

link

answered 06 Jan '12, 19:48

ryans's gravatar image

ryans ♦♦
3.8k1931
accept rate: 44%

Your answer
toggle preview

Follow this question

By Email:

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

By RSS:

Answers

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

Tags:

×157
×92
×27
×24
×8

Asked: 05 Aug '11, 20:24

Seen: 1,869 times

Last updated: 06 Jan '12, 19:48

Plans & prices    Sign up    Why WebFaction?    Contact us    Affiliate program    Support    Legal    Jobs    Blog    Control panel login
Powered by OSQA
© Copyright 2003-2012 Swarma Limited - WebFaction is a service of Swarma Limited