问题
While I understand that Passenger 5 is currently the standard, I have a unique use case requiring me to use Passenger 4 while I upgrade a current application. I can't seem to find any particular instructions on how to install Passenger 4 from the Passenger site. I also cannot seem to find any apt repositories with Passenger 4 either.
Are there any resources available for doing this? And can this be done via apt?
回答1:
Found out the answer in this old blog article from Phusion.
The Passenger Phusion repo can only hold one version of the distro (now it holds version 5). So, you need to set the repo location in the /etc/apt/sources.list.d/passenger.list (on Ubuntu) to use the specified string in the blog article. Once you do this when installing Passenger on the server you will pull in the Passenger 4 repo instead of the Passenger 5 repo.
The following additional points will also help in the installation:
- To get the VirtualHost (via Passenger 4 on Apache) to run a specific version of ruby by way of RVM, this article was helpful to have.
- Next, if you have to use a ruby version earlier than 2.0, you may get a problem "undefined method `source_index' for Gem:Module (NoMethodError)". If so use this to update your gemset to resolve the issue.
来源:https://stackoverflow.com/questions/37687959/how-to-install-phusion-passenger-4-on-ubuntu-on-apache2-or-nginx