Hi Chris,
We’ve just managed to get ruby 1.6.7, mod_ruby-1.0.2 and apache2 working
here. I didn’t install apache but using phpinfo() I found the following:
Configure Command ‘./configure’ ‘–with-apxs2=/usr/local/apache2/bin/apxs’
‘–enable-mbstring’ ‘–with-oci8’ ‘–with-oracle’
_ENV[“SERVER_SOFTWARE”]Apache/2.0.43 (Unix) PHP/4.2.3 mod_ruby/1.0.2
Ruby/1.6.7
I compiled mod_ruby with:
./configure.rb --with_apxs=/usr/local/apache2/bin/apxs
and then did ‘make install’.
We followed the instruction from rubydoc.net and added this to httpd.conf:
LoadModule ruby_module libexec/apache/mod_ruby.so
#AddModule mod_ruby.c
#
RubyRequire apache/ruby-run
<FilesMatch “.rbx”>
Options +ExecCGI
SetHandler ruby-object
RubyHandler Apache::RubyRun.instance
RubyRequire apache/eruby-run
<FilesMatch “.rhtml”>
SetHandler ruby-object
RubyHandler Apache::ERubyRun.instance
#
Note we didn’t add the AddModule line and hence we had to comment the
IfModule lines to get it to pickup the handlers. If anyone how this should
be done with apache2 please let me know. I think that’s all.
Hope that helps,
Martin
···
-----Original Message-----
From: Chris Pine [mailto:nemo@hellotree.com]
Sent: Thursday, 19 December 2002 5:55 AM
To: ruby-talk@ruby-lang.org
Subject: Re: Ruby instead of PHP?----- Original Message -----
Chris, did you ever get it to work for the following combination:
ruby, mod_ruby, eruby, and apache 2.0.43?Nope, never did. When I switched from PHP to Ruby, it was on
a RedHat 7.3
machine, which installed the older Apache by default. When I
was trying to
get mod_ruby working with Apache 2, that was on my wife’s
RedHat 8 machine.
(RedHat 8 installs Apache 2 by default.)I did get ruby and eruby working just fine; it was mod_ruby
that was the
problem. Since it was just my wife’s machine and not a major
web-server, I
decided to simply run Ruby as cgi. It worked just fine. Slower than
mod_ruby would be, but in this case (not more than 10 hits a
day) speed is
not an issue.Chris