Running a different ruby with Passenger 3.2 and RVM

Passenger 3.2 will have quite some nice new features. 1 2 The features I’m looking forward to most is the ability to specify - per virtual server - which ruby to use. Before, you installed passenger and specified the required ruby version using passenger_ruby, like this in your nginx.conf: http { passenger_root /opt/passenger; passenger_ruby /usr/local/bin/ruby; server { server_name; passenger_enabled on; } } Now, if you added another server it would be forced to use the same ruby version.

Automatically switch between SSL and non-SSL with Nginx+Unicorn+Rails

Scroll down for setup instructions. Or, read this bit about SSL in the real world first. SSL or Secure Socket Layer is a nice way to secure sensitive parts of your Rails application. It achieves to goals. Firstly is encrypts all traffic between you and the remote server. Consider the passwords and personal information you submit to websites. When unencrypted (using HTTP), all this data is sent over the internet for all to read.

Lighting fast, zero-downtime deployments with git, capistrano, nginx and Unicorn

Everyone who has ever developed a web app has had to deploy it. Back in the day you simply uploaded your files with FTP and everything would be good. Today we have to clone git repositories, restart servers, set permissions, create symlinks to our configuration files, clean out caches and what not. Doctor, what’s wrong? In my opinion there are two critical problems with deployments today: They are slow They cause downtime Both topics have been discussed by the likes of Twitter and Github.