Comment on Tunnelling a port from a separate computer
cecilkorik@lemmy.ca 9 months agoYou can also automate this with autossh which is designed for exactly this kind of persistent tunnel. Although a simple “while” loop might seem like the intuitive way to keep it running, autossh is very reliable and takes care of all the corner cases for you.