title: Phusion Passenger Running Different User
body: <p>I have created a Rails app that I want to run on my server. Somebody else created the basic skeleton on the Apache server, and they installed rvm, rails, etc.
  I pulled the project and have been working on it, so I created a new Virtual Host and in my etc/hosts I'm pointing to it. The problem I think is that Passenger is running it as my username but it looks for a different user with a different environment to run my web app.
  I asked the other person how to fix this and he has no idea.</p>
  
  <p>I've tried doing bundle and sudo bundle, and then pushing to my server (cyberduck) but it's still giving me the same problem.</p>
  
  <p>Here's the error:</p>
  
  <pre><code>It looks like Bundler could not find a gem. Maybe you didn't install all the gems that this application needs. To install your gems, please run:
  
  bundle install
  If that didn't work, then the problem is probably caused by your application being run under a different environment than it's supposed to. Please check the following:
  
  Is this app supposed to be run as the username user?
  Is this app being run on the correct Ruby interpreter? Below you will see which Ruby interpreter Phusion Passenger attempted to use.
  Please check whether the correct RVM gemset is being used.
  Sometimes, RVM gemsets may be broken. Try resetting them.
  -------- The exception is as follows: -------
  
  Could not find globalid-0.3.5 in any of the sources (Bundler::GemNotFound)
    /home/username2/.rvm/gems/ruby-2.2.1/gems/bundler-1.9.2/lib/bundler/spec_set.rb:92:in `block in materialize'
    /home/username2/.rvm/gems/ruby-2.2.1/gems/bundler-1.9.2/lib/bundler/spec_set.rb:85:in `map!'
    /home/username2/.rvm/gems/ruby-2.2.1/gems/bundler-1.9.2/lib/bundler/spec_set.rb:85:in `materialize'
  </code></pre>