Rails in a Windows World

I work at an organization that is very wrapped up in Microsoft products.
I
am trying to get a test application put in however I’m not sure what to
do
about the infratstructure. If it were up to me we would put in MySQL
and
Apache or Lighty, however its not up to me. The easiest way to get an
application into production at our company would be to use the existing
MS
SQL server and IIS infrastructure. Does anyone have experiences with
this?
If its relatively easy then I will suggest we go with that. However, if
its
more trouble than its worth, I’ll suggest we put together a more
traditional
Rails environment. Thoughts? Suggestions? I appreciate any advice.

Joe

Joe,

AFAIK, IIS won’t proxy like Apache can, so I don’t think IIS is the way
to go. SQL Server is supported, but less ideal for Rails. The first
thing I would look into is Mongrel and its Windows service capabilities.
This handles the HTTP side. Apache 2.2.3 does run on Windows, as does
MySQL and PostgreSQL, so you may be able to prove the commercial support
behind MySQL and PostgreSQL and the market dominance of Apache - at
least these are not horriffic hacks, they are normal Windows installs
and work great.

Does this org use any Linux or *BSD systems for email, NFS/Samba file
storage, or firewalling? If this is OK for their IT department, you’ve
won half the battle. If not, they are totally drinking the koolaid and
not realizing that their tech choice was bought by vendor marketing
rather than driven by a very smart developer community (with some big
name converts!).

So, Mongrel or Apache+Mongrel for web, SQL Server for DB - give it a
shot. If they are watching the industry as they should be, they see the
Ruby/Rails tidal wave coming. If you can get them to allow a small
internal project, that’s your foot in the door, so to speak.

I work in a mostly MS shop (some Linux, some Java) but the powers that
be know Rails is making a huge splash. It’s two years old, so it’s not a
‘fad’ anymore.

If all else fails, check out http://www.castleproject.org/ and its
MonoRail and ActiveRecord projects - Rails-like development in .NET. Or
get a different job. :slight_smile:

Sorry for the rant - need sleep. Zzzz.

Cheers,

Kevin

Joseph A. wrote:

I work at an organization that is very wrapped up in Microsoft products.
I
am trying to get a test application put in however I’m not sure what to
do
about the infratstructure. If it were up to me we would put in MySQL
and
Apache or Lighty, however its not up to me. The easiest way to get an
application into production at our company would be to use the existing
MS
SQL server and IIS infrastructure. Does anyone have experiences with
this?
If its relatively easy then I will suggest we go with that. However, if
its
more trouble than its worth, I’ll suggest we put together a more
traditional
Rails environment. Thoughts? Suggestions? I appreciate any advice.

Joe

Joseph A. wrote:

I work at an organization that is very wrapped up in Microsoft products.
I
am trying to get a test application put in however I’m not sure what to
do
about the infratstructure. If it were up to me we would put in MySQL
and
Apache or Lighty, however its not up to me. The easiest way to get an
application into production at our company would be to use the existing
MS
SQL server and IIS infrastructure. Does anyone have experiences with
this?
If its relatively easy then I will suggest we go with that. However, if
its
more trouble than its worth, I’ll suggest we put together a more
traditional
Rails environment. Thoughts? Suggestions? I appreciate any advice.

Joe

Hi,

There are some reverse proxy modules / handlers for IIS/asp.net, so you
could use that with Mongrel. Never got file uploads working and haven’t
found the time to try harder. Also I never found a load balanced proxy
like mod_proxy in Apache, so if you need to scale you have to be
creative. For example use iis - reverseproxy - squidNT - multiple
Mongrels. Actually - if it’s a MS-shop your in it shouldn’t be to hard
to spend a little while on a nice loadbalanced reverse proxy module in
.NET. Sort of a say goodbye project ;-).

From the short tests I did, SQL Server seemed to work okay.

/Boris

Deployment on Windows is my specialty actually… and it’s very
possible.
There will be information about this in the upcoming Rails deployment
book.

  1. IIS will not work. There’s just no way. Not gonna happen.
  2. You can use Mongrel which runs beautifully under Windows as a
    service.
    You are limited though by the speed of Ruby on Windows which can be much
    slower than on Linux. For public applications, a single instance of
    Mongrel
    won’t cut it. For those situations, you’ll need to use two or more
    Mongrel
    instances behind a proxy like Apache 2.2.
  3. You can hide all of this behind an existing IIS infrastructure using
    ISAPI_Rewrite and a plugin I’ve written… this way you get to use your
    existing SSL certificates and things look transparent.

Anyone who needs guidance can certainly contact me on these issues. I
can
provide deployment assistance as well.

On 8/2/06, Brian H. [email protected] wrote:

ISAPI_Rewrite and a plugin I’ve written… this way you get to use your
existing SSL certificates and things look transparent.

+111111 Brian

I’m in a similar situation as Joseph, but I wont discuss more about
that.

I’ve walked in the IIS+FastCGI land, and got a fonctionnal Rails apps
now, but with too much pain and too much efforts.

As web developer you have to tame your pages for fitting in IE, be
prepared to some surprises also with IIS. Some redirect_to in your
application running smothly with apache, webrick will fails on IIS. In
my constant evolving apps, each ‘put in IIS production mode’ is
followed by IIS behavior correctives. tired!

Next stage for me, because I will run more than 1 Ror apps on that
@#}$! IIS, will be using :

  • IIS as front http server
  • ISAPI Rewrite
  • Mongrel sit in the background and serving the nice job.

Having the same http server (mongrel) in dev on your workstation and
in production behind IIS, is a very strong argument also.

Brian has published nice documentation about that :
http://www.napcsweb.com/howto/rails/deployment/railsonIISWithMongrel.pdf

The guide seem a bit complex, but nothing compared to IIS/FastCGI.

Your “Administrators” just have to tolerate a new Win service as
Mongrel in their servers listenting on port 4001 for example.

Regards,

That guide’s not complex…I’m just very detailed :slight_smile:

Brian, I wrote that for a Rail’s beginner point of view, apol…

That guide’s not complex…I’m just very detailed :slight_smile:

Just want to say that the guides for various setups posted on my site
are a
bit out of date. They’re not getting rewritten because this information
is
going into the upcoming book. For example, the command used to
install
mongrel as a service has changed since that was written.

no need to apologize at all, and thank you for the kind words.

As an FYI to this thread. I am just starting work on Instant Rails 1.4
which is going to drop SCGI and use Mongrel instead. That will give a
prepackaged runtime for Apache/Ruby/Rails/MySQL that uses Apache to
proxy requests to Mongrel.

Curt

No, Apache 2.x will be in Instant Rails 2, which is a complete rewrite
(and multi-platform, to boot). But IR 2 probably won’t be out until
next year.

Curt

Curt:
Awesome!

Will this be using Apache 2.2, and will it have support for SSL?

Joseph A. wrote:

I work at an organization that is very wrapped up in Microsoft products.
I
am trying to get a test application put in however I’m not sure what to
do
about the infratstructure. If it were up to me we would put in MySQL
and
Apache or Lighty, however its not up to me. The easiest way to get an
application into production at our company would be to use the existing
MS
SQL server and IIS infrastructure. Does anyone have experiences with
this?
If its relatively easy then I will suggest we go with that. However, if
its
more trouble than its worth, I’ll suggest we put together a more
traditional
Rails environment. Thoughts? Suggestions? I appreciate any advice.

Joe

I understand your ploy. The same happend with out department, our agile
manager saw the rails and ruby combination sweeping over the world and
now I must learn Ruby on Rails. I honestly like the convention over
configuration idea. We are to Microsoft Partners, with lots of
gratifications and certifications from Microsoft, but that does not stop
us to work on what platform we want. I personaly work on Linux and
Windows, but all the major company’s are moving towards open-source.
That is the trend right now, so you either fight with it, or go with the
flow.

Thanks for the help on this everyone. I know that webrick isn’t meant
to be
a heavy duty production web server, but if we had an application with
only a
few (less than 5) users and a not very complex application would it be
acceptable?

I think getting something like MySQL into my company wouldn’t be too
difficult. But they are EXTREMELY open source adverse. So Apache and
mongrel and solutions like that could be difficult. It’s too bad that
IIS
isn’t really an option (not that I like it, but some people are kind of
forced into it).

From all the comments it sounds like trying to force a Rails app into
something like IIS and/or MS SQL Server would be a bad choice for a
first
Rails app. I would hate for my little experiment to fail because of
infrastructure problems. Thanks.

Joe

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs