Monday, February 29, 2016

Upgrading from Passenger 4.0.60 to 5.0.25

If you are managing your Rails 4.2.5 server using Moonshine, follow these steps.

Step 1

In passenger.rb, within Moonshine::Manifest::Rails::Passenger module, change the passenger version:

```ruby
BLESSED_VERSION = '5.0.25'
```

Step 2

Add the following Capistrano 2 task to deploy.rb:

namespace :deploy do
  task :restart, :roles => :app, :except => { :no_release => true } do
    sudo "passenger-config restart-app --ignore-app-not-running /srv//current"
  end
end

Checkin the code changes to git and deploy the app using Capistrano.

Step 3

On the server, verify the installed version:

```sh
passenger-config --version
```

Page Load Time

In passenger 4.0.60, it took 2.4 s
In passenger 5.0.25, it took 1.7 s