Forum: Ruby on Rails Anybody using SCGI in production?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
cool_screen_name90001 (Guest)
on 2005-11-21 05:33
(Received via mailing list)
Or does anybody prefer fastcgi/fcgi? I'm using webrick for development,
but plan on using scgi
when I switch to production (because it appears to be an update to
fastcgi, and I couldn't get
fastcgi working anyhow).

thanks
csn




__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com
jqshenker (Guest)
on 2005-11-21 07:18
(Received via mailing list)
I'm working with FastCGI for the time being, but I too plan to move to
SCGI when I find a couple minutes in which to do so. Also, TextDrive's
RailsBase will be *all* SCGI, it's definitely going to get a lot of
production use there. Whatever works for you, go for it, but SCGI does
seem preferrable to FastCGI. Seems simpler to set up, too.

Jacob
jeremyevans0 (Guest)
on 2005-11-21 19:29
(Received via mailing list)
On 11/20/05, CSN <removed_email_address@domain.invalid> wrote:
> Or does anybody prefer fastcgi/fcgi?

I'm now using SCGI for all my production sites.  It's simple to
configure and I haven't had any reliability issues.  Most of the sites
run on lighttpd, though one runs on Apache with cgi2scgi.
hypsometry (Guest)
on 2005-11-22 04:41
(Received via mailing list)
I'm using both. In one case (Textdrive) FCGI was already set up, so
that was easy. In another it wasn't, so SCGI proved far easier to deal
with.

SCGI has been great.

--
Chris B.

http://hypsometry.com/  :  website edification
http://uvlist.org/  :  free classifieds for the Upper Valley
peter.fitzgibbons (Guest)
on 2005-11-22 08:50
(Received via mailing list)
I'd like to hear a back-poll on this...
each of you : Windows or linux? Which version/distribution?
 Thanks!
hypsometry (Guest)
on 2005-11-22 16:09
(Received via mailing list)
On 11/22/05, Peter F. <removed_email_address@domain.invalid> wrote:
> I'd like to hear a back-poll on this...
> each of you : Windows or linux?  Which version/distribution?

Uh, none of the above. ;)

Textdrive runs FreeBSD. The other app is served from OS X Server. In
both cases Apache's receiving the request and proxying it to lighttpd.

--
Chris B.

http://hypsometry.com/  :  website edification
http://uvlist.org/  :  free classifieds for the Upper Valley
jinslee (Guest)
on 2005-11-22 19:59
(Received via mailing list)
I run SCGI on Windows 2000 Server + Apache2. Runs like a dream. Its fast
in
development mode and even faster in production.
jeremyevans0 (Guest)
on 2005-11-22 20:07
(Received via mailing list)
On 11/21/05, Peter F. <removed_email_address@domain.invalid> wrote:
> I'd like to hear a back-poll on this...
> each of you : Windows or linux?  Which version/distribution?

OpenBSD for the lighttpd sites.  The Apache site is some version of
Linux running in a VPS.
cool_screen_name90001 (Guest)
on 2005-11-22 21:51
(Received via mailing list)
--- Chris B. <removed_email_address@domain.invalid> wrote:
>
> In both cases Apache's receiving the request and
> proxying it to lighttpd.

What do you guesstimate the performance difference to be, versus using
only Lighttpd? I'm thinking
of trying Lighttpd, but will probably have to keep Apache around.

thanks
csn



>
__________________________________
Yahoo! FareChase: Search multiple travel sites in one click.
http://farechase.yahoo.com
peter.fitzgibbons (Guest)
on 2005-11-23 00:04
(Received via mailing list)
HI Jin,
How do you run SCGI ? Do you run it as a service ? Where did you get
your
binaries... I think I'm having trouble with binary version or something.
jinslee (Guest)
on 2005-11-23 00:20
(Received via mailing list)
Yes, I run SCGI as a service.

All you need to do is adopt the instiki instructions, located here:
http://www.instiki.org/show/Running+as+a+Windows+Service

For reference, here are my registry keys:

AppDirectory = (path to your web app, not the public directory but the
root
of the rails app)
Application = c:\ruby\bin\ruby.exe
c:\path_to_your_webapp\script\scgi_service

Everything else I got from zedshaw's website,
http://www.zedshaw.com/projects/scgi_rails/index.html
if you are looking for a built mod_scgi.so file, check out Curt H.'
build
here: http://www.zedshaw.com/projects/scgi_rails/win32.html

The other essential part is to hook it up to Apache2, here is the
relevant
part of my httpd.conf:

#Ruby/RAILS
LoadModule scgi_module modules/mod_scgi.so

<VirtualHost *:80>
AddDefaultCharset utf-8
ServerAdmin removed_email_address@domain.invalid
DocumentRoot "C:/path_to_your_webapp/public"
ServerName www.blah.com <http://www.blah.com>
ErrorDocument 500 /500.html
ErrorDocument 404 /404.html
# handle all requests throug SCGI
SCGIMount / 127.0.0.1:9999 <http://127.0.0.1:9999>
# matches locations with a dot following at least one more characters,
that
is, things like *,html, *.css, *.js, which should be delivered directly
from
the filesystem
<LocationMatch \..+$>
# don't handle those with SCGI
SCGIHandler Off
</LocationMatch>
<Directory "C:/path_to_your_webapp/public">
Options +FollowSymLinks
Order allow,deny
allow from all
</Directory>
</VirtualHost>

Hope that helps,

Jin
This topic is locked and can not be replied to.