Created
August 28, 2019 11:12
-
-
Save thinktainer/11c6b5f4fe444ea8d09e6cab4549d739 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
case $1 in | |
start) | |
autossh -f -M 0 -Nn -D 127.0.0.1:2431 jumpbox.prod.gcp.uw.systems | |
autossh -f -M 0 -Nn -D 127.0.0.1:2430 jumpbox.dev.gcp.uw.systems | |
autossh -f -M 0 -Nn -D 127.0.0.1:2429 jumpbox.prod.uw.systems | |
autossh -f -M 0 -Nn -D 127.0.0.1:2428 jumpbox.dev.uw.systems | |
;; | |
stop) | |
ps aux | rg 'autossh.*uw\.systems' | cut -d ' ' -f 2 | xargs kill | |
;; | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment