Topic: Setting up Ruby on Rails for OS X Server

I've installed OS X Server. It installs apache and you can work with Server Admin

I'm having a hard time setting up rails with apache.

I followed HiveLogic's installation
http://hivelogic.com/narrative/articles … ysql_tiger

So whats left is linking Rails and Apache together.
What do I need to do?

Re: Setting up Ruby on Rails for OS X Server

You probably want to set up apache with mongrel proxy. See the link for details.

Railscasts - Free Ruby on Rails Screencasts

Re: Setting up Ruby on Rails for OS X Server

So I checked what version of apache I was running. httpd -v
And its 1.3.3 so I went and installed apache 2.2 following the instructions guides.
But I haven't re-configured my httpd.conf.
When I run httpd -v it still says its its 1.3.3. Have I installed apache properly?

Re: Setting up Ruby on Rails for OS X Server

Do you know which directory the new apache is installed? You probably have to set it up in your user paths so httpd refers to the newer version.

Railscasts - Free Ruby on Rails Screencasts

Re: Setting up Ruby on Rails for OS X Server

It appears to be installed at /usr/local/bin/apache2 I think.
Im not sure how the apache 1.3 was setup since it was done by the os x server installation cd.

But if I run httpd -v and it says 1.3 Im guessing its not calling apache2.
So where would I say look at apache2?

Re: Setting up Ruby on Rails for OS X Server

is there an "httpd" executable in your /usr/local/bin directory? If so, try running it directly:

/usr/local/bin/httpd -v

Railscasts - Free Ruby on Rails Screencasts

Re: Setting up Ruby on Rails for OS X Server

It's in /usr/local/apache2/bin

but I can't seem to get it to run.

Re: Setting up Ruby on Rails for OS X Server

so this doesn't work? What does it say?

/usr/local/apache2/bin/httpd -v

Railscasts - Free Ruby on Rails Screencasts

Re: Setting up Ruby on Rails for OS X Server

It will come up with apache 2.2.4

Re: Setting up Ruby on Rails for OS X Server

I had this same problem.  You need to disable the initial Apache 1.3 install via Server Admin.  Since it sounds like you have Apache2 installed, you will need to create a startup item for it so that you'll be using the correct version.  You can follow the instructions here:

http://diymacserver.com/installing-apac … e-at-boot/

Once you have that going, you should be able to follow the previous doc that Ryan posted which will show how to have Apache2/Mongrel handle the front end to your app.  Good luck!

Re: Setting up Ruby on Rails for OS X Server

Is there anything wrong with just using apache 1.3?