Something like this ought to work:

   require 'capistrano'
   config = Capistrano::Configuration.new
   result1 = config.capture("some command", :hosts => "server1")
   result2 = config.capture("some command", :hosts => "server2")

Hope that helps,

Jamis

On Jun 5, 2007, at 4:04 AM, psimoes wrote:

>
> Hello,
>
> I'm developing a rails application and I need to run some shell
> commands on remote machines and get the output. The rails application
> runs centralized in a server that controls the remote machines. I'm
> not interested in deployment. How can I use the Capistrano API to
> simply instruct the application to run those commands remotely? I'm a
> little confused how I set the target hosts.
>
> Thanks
>
>
> >


--~--~---------~--~----~------------~-------~--~----~
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/capistrano
-~----------~----~----~----~------~----~------~--~---

Reply via email to