WARNING: This script hasn't been tested yet. Hopefully I'll be back in a couple of weeks to tidy it up, finish it off, and document it properly. I'm just checking it in now so I don't lose it before I get a chance to sort it all out.
This repo contains things that help you get cijoe running under Phusion Passenger. The bulk of the hard work (working out a sane way to do it) was done Chris Parsons, and you can read about how he did it in his Multiple CI Joes with Rack and Passenger blog post.