0

At work I have a SuSE 7.3 running Apache 1.3.20, which I don't have admin access to. I'd like to deploy Ruby on Rails with no or very little work for the admins.

I need the service to keep running all the time, even if the server is rebooted, I need it to run faster than CGI-Speed and I'd like to have a simple domain without ports.

What are my options?

blinry
  • 111
  • 3

2 Answers2

0

Run rails on another server (nginx+mod_rails is my favourite, but lighttpd, mongrel or something similar should do) and just ask the admins to reverse proxy this from apache.

ptman
  • 28,394
  • 2
  • 30
  • 45
0

Running Rails on Apache 1.3 is going to be far more painful than on a 2.x system.

You will either need to run mongrels locally (perhaps configured by an admin of that server to start up correctly) on specific port numbers per application, and then use some proxy magic to send Apache there, or on a different machine. If you choose to run on a different machine, install Apache 2.0 and use Phusion Passenger. It will make your life easier.

Example Passenger config for a new site on Apapche:

<VirtualHost *:80>
  ServerName blog.flame.org
  DocumentRoot /www/blog/flame-blog/current/public
  ExpiresDefault "access plus 10 years"
</VirtualHost>

I put this in a file called /local/httpd/sites/blog.flame.org.conf, then use this in my httpd.conf file:

Include /local/httpd/sites/*.conf

IMHO, it doesn't get any easier to add a new site than this, if you want to maintain command line driven config management.

As for deploying a new version of a RoR application, using Capistrano, it's literally as easy as typing cap deploy:migrations to push a new version out, and if you mess up, cap deploy:rollback to undo it. Whee.

I would use Capistrano to deploy your applications no matter how you choose to serve them.

Michael Graff
  • 6,668
  • 1
  • 24
  • 36