Configuring Passenger sub-URIs

Passenger sub-URIs allow you to run multiple Rails aplications under one Apache virtual host, which is great for development. Although Phusion has documented how to do this, I was having trouble. Eventually I got it to work, by doing the steps below: The Apache default DocumentRoot location is /var/www/html. I created a new directory and changed DocumentRoot to /var/www/public As root, cd /var/www/public. Add a link to each public directory of each Rails app to be accessed. On Linux, this looks like ln -s /somewhere/MyApp1/public MyApp1, where MyApp1 was created by running rails MyApp1 under the directory /somewhere Modify the Apache httpd.conf file. DocumentRoot was changed as shown in Step… Read More

Continue Reading

Goodbye Mongrel, Hello Passenger

Mongrel has been a great web server for Ruby and Rails, but with the significant changes in Ruby 1.9.1 (native threads for instance), I decided to switch to Phusion Passenger and Apache. If nothing else, this will keep me working with Apache (it is the A in LAMP, after all). The gem install passenger ran as we would expect, but passenger-install-apache2-module had a bunch of complaints. Mainly, I needed to install a number of development RPMs for Fedora Core 8 Apache. Also, passenger could not see the OpenSSL libraries. Sure enough, the mkfm.log file under ext/openssl in the Ruby 1,9.1 tree showed a number of errors that seemed to indicate… Read More

Continue Reading