Forum: Ruby on Rails Location to startup DRb Server

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.
Michael K. (Guest)
on 2006-03-20 16:58
(Received via mailing list)
Hello,

where (in which file/object) would I invoke the startup of the DRb
server to
support a rails application?


It wouldn't be config/boot.rb ?

How would I shut it down cleanly?


Greetings

Michael K.
Scott W. (Guest)
on 2006-03-21 20:46
(Received via mailing list)
On Mar 20, 2006, at 6:59 AM, Michael K. wrote:

> Hello,
>
> where (in which file/object) would I invoke the startup of the DRb
> server to support a rails application?
>
>
> It wouldn't be config/boot.rb ?
>
> How would I shut it down cleanly?

Michael,

I start the DRb server as a separate process:
./script/runner RemoteServer.start

In testing, I just run/kill the process in the terminal.

In prod, I have a script: /etc/rc.d/drb

You should probably use PIDs and startproc, etc., but I just stop it
with:
pkill -KILL -f 'RemoteServer'

I imagine there is a way to install a Ruby script as a Windows
Service, too.

Hope that helps,
Scott
This topic is locked and can not be replied to.