def try_open_tunnel(server, options)
      host, user = options[:tunnel].split('@').reverse #for ssh to the gateway host
      user ||= ENV['USER']
      begin
        @gateway = Net::SSH::Gateway.new(host, user)
        gateway.open(server.name, options[:port]) do |port|
          self.open('127.0.0.1', options.merge({:port => port}))
        end
      rescue => e
        e
      end
    end
def try_open_tunnel(server, options)
      host, user = options[:tunnel].split('@').reverse #for ssh to the gateway host
      user ||= ENV['USER']
      begin
        @gateway = Net::SSH::Gateway.new(host, user)
        gateway.open(server.name, options[:port]) do |port|
          self.open('127.0.0.1', options.merge({:port => port}))
        end
      rescue => e
        e
      end
    end
call plugin open() via an ssh tunnel