Created
January 18, 2017 17:23
-
-
Save johnkmj/8bb18889aa3dccb1b70f37935b4ef2e2 to your computer and use it in GitHub Desktop.
1-liner command to initiate and maintain a ssh tunnel. Replace with correct info. Pop in crontab -e
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@reboot while true; do sleep 10; autossh -M 10985 -i ~/.ssh/id_rsa_new -f -N -R 0.0.0.0:1337:localhost:1337 root@212.47.252.178; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment