1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-23 22:50:09 +03:00

f : add timeout to SshStreamCommand#run

This commit is contained in:
Javi Fontan 2016-09-12 11:54:31 +02:00
parent 85d265cad7
commit 6cb9635bdb

@ -192,7 +192,9 @@ class SshStreamCommand < RemotesCommand
@stream = SshStream.new(host, shell, timeout)
end
def run(command, stdin=nil, base_cmd = nil)
def run(command, stdin=nil, base_cmd = nil, timeout = nil)
@timeout = timeout if timeout
@stream.open unless @stream.opened?
if base_cmd #Check if base command is on remote host