Fork me on GitHub
#emacs
<
2017-05-24
>
qqq06:05:12

is there a way for emacs to manave a ssh -L

qqq06:05:21

so I have this ssh command whose sole purpose in line is to do port forwarding

qqq06:05:31

however, sometimes, it hangs / I need to restart it

qqq06:05:38

Is there a way to have emacs manage all this for me?}

tanzoniteblack14:05:09

@qqq that sounds like a better job for a user spaced systemd unit (https://wiki.archlinux.org/index.php/Systemd/User) or whatever your init system of choice is (launchctl if you're on a mac?)

qqq14:05:33

@tanzoniteblack : that's interesting; I'm not sure how to trigger the 'detect hang'

qqq14:05:55

part of the problem I have is: (1) I ssh -L, (2) I put mbp to sleep, (3) when I return , the ssh is running but the port forwarding is deadc

qqq14:05:07

but I am convincedc of one thing now, emacs is the wrong place to put this

tanzoniteblack14:05:10

a quick google search finds suggestions to use http://www.harding.motd.ca/autossh/ for this use case, ( https://superuser.com/a/37768 mentioned it, as does a few others )

tanzoniteblack14:05:59

and that's available in homebrew, I think, so should be painless to install and see if it does fix it for you?