title: How can I define PATH for Phusion Passenger under nginx with Bundler?
body: <p>Please forgive my near total ignorance of Ruby, but I am having an issue with Phusion Passenger in that it attempts to run something that relies on $PATH (and blindly assumes it is defined and a string). However, nginx evidently clears out the variable.</p>
  
  <pre><code>Error message:
      private method `split' called for nil:NilClass
  
  ...
  
  Backtrace:
  #   File                                                       Line  Location
  0   /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.0/lib/bundler.rb 254   in `which'
  </code></pre>
  
  <p>That line reads:</p>
  
  <pre><code>        path = ENV['PATH'].split(File::PATH_SEPARATOR).find do |p|
  </code></pre>
  
  <p>If there is a workaround for this, I would greatly appreciate it, as I would like to avoid using Apache if at all possible.</p>