lib/capistrano/forwarding/remote.rb
def remote_forwarding(fowardings, options = {})
      options = add_default_command_options(options)
      execute_on_servers(options) do |servers|
        targets = servers.map{|s| sessions[s]}
        Forwarding::Remote.forward(fowardings, targets) do
          yield
        end
      end
    end
# Capistrano configuration example.
# Forwarding remote port 3000 to local 3000 and ask remote hosts to HTTP GET
# from local HTTP server running on port 3000.
#   remote_forwarding [
#     [3000, "127.0.0.1", 3000]
#   ] do
#     run "curl 'http://127.0.0.1:3000/'"
#   end
Capistrano configuration example.
Forwarding remote port 3000 to local 3000 and ask remote hosts to HTTP GET
from local HTTP server running on port 3000.
Capistrano configuration example . Forwarding remote port 3000 to local 3000 and ask remote hosts to HTTP GET from local HTTP server running on port 3000 .
def remote_forwarding(fowardings, options = {})
      options = add_default_command_options(options)
      execute_on_servers(options) do |servers|
        targets = servers.map{|s| sessions[s]}
        Forwarding::Remote.forward(fowardings, targets) do
          yield
        end
      end
    end
def remote_forwarding ( fowardings , options = { } ) options = add_default_command_options ( options ) execute_on_servers ( options ) do | servers | targets = servers . map { | s | sessions [ s ] } Forwarding :: Remote . forward ( fowardings , targets ) do yield end end end
Capistrano configuration example.
Capistrano configuration example .
fowardings
options