Fabric: Reinstate keepalive control

Created on 19 Jun 2018  ·  4Comments  ·  Source: fabric/fabric

v1 had a simple integer env.keepalive / --keepalive that got turned into client.get_transport().set_keepalive(xxx); v2 has not ported that over yet.

Feature Needs patch Network

Most helpful comment

Any update on if this can be ported soon? Seems like a simple fix.

All 4 comments

Any update on if this can be ported soon? Seems like a simple fix.

I'd also like this to be implemented.

How would one implement this functionality currently with Fabric2? Or, is it even possible?

This might be a dirty workaround, but it might be possible to set the timeout this way:
from fabric2 import Connection
c = Connection(host="1.2.3.4", user="user", connect_kwargs={"key_filename": "my_key"}
c.run("echo hey")
c.transport.set_keepalive(<keepalive>)

I didn't find a different way to set keepalive with fabric2 at the moment ):

Was this page helpful?
0 / 5 - 0 ratings

Related issues

supriyopaul picture supriyopaul  ·  4Comments

neemxyang picture neemxyang  ·  6Comments

TimotheeJeannin picture TimotheeJeannin  ·  3Comments

Grazfather picture Grazfather  ·  4Comments

acdha picture acdha  ·  4Comments