From: Paul Lutus Date: 2006-12-05T05:40:05+09:00 Subject: Re: ruby web servers, threads and sessions eching wrote: > > Eric Hodel wrote: >> On Dec 4, 2006, at 11:20 , eching wrote: >> >> > Is there a pure ruby web server that can start a thread that performs >> > some task and store it in a session allowing the user to control the >> > task from the browser? Similar to a what I can do with a java web >> > server? >> >> WEBrick + your custom code. >> >> -- >> Eric Hodel - drbrain@segment7.net - http://blog.segment7.net >> >> I LIT YOUR GEM ON FIRE! > > Ah, looks pretty straight forward, thanks. > > Ok, so is it realistic to start up a Drb server and store it in a > session? Really what I am looking to do is to be able to control ruby > applications on various hosts from a web client using the web server as > the central hub. > > The basic idea is a distributed log scanner app where the user can > control (add files, remove files, change search string) "scanning > agents" that are running on different hosts. Yes, you can do this, but if the purpose is to govern the behavior of remote machines, and if there are any security issues, I personally would do it using SSH instead. You could set things up to tunnel the webrick content through an SSH connection. That is a way to balance ease of use with good security. I am not perfectly clear about what you are trying to accomplish, but if your description is a suitable guide, then maybe a text-based SSH remote execution approach might be better than one based on a a Web server. -- Paul Lutus http://www.arachnoid.com