mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-28 13:21:25 -07:00
Merge pull request #6507 from brdo/patch-1
Set keepalive to 5 seconds in paramiko_ssh.py
This commit is contained in:
commit
e5ef0eca03
1 changed files with 1 additions and 0 deletions
|
@ -186,6 +186,7 @@ class Connection(object):
|
||||||
bufsize = 4096
|
bufsize = 4096
|
||||||
try:
|
try:
|
||||||
chan = self.ssh.get_transport().open_session()
|
chan = self.ssh.get_transport().open_session()
|
||||||
|
self.ssh.get_transport().set_keepalive(5)
|
||||||
except Exception, e:
|
except Exception, e:
|
||||||
msg = "Failed to open session"
|
msg = "Failed to open session"
|
||||||
if len(str(e)) > 0:
|
if len(str(e)) > 0:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue