Last active
June 5, 2021 15:05
-
-
Save yayoimizuha/657b7824cd93f3d4f3597073b2d296dc 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
SERVER_USER="mizuha" | |
SERVER_ADDR="153.127.6.191" | |
SERVER_PORT="11022" | |
hash gh 2>&1 /dev/null | |
if [ $? = 0 ]; then | |
ssh ${SERVER_USER}@${SERVER_ADDR} -p ${SERVER_PORT} "echo \"$(gh gist view $1)\" >> /home/${SERVER_USER}/.ssh/colab_ssh_keys" | |
gh gist delete $1 | |
for i in {10000..10020}; do | |
ssh -L ${i}:localhost:${i} ${SERVER_USER}@${SERVER_ADDR} -p ${SERVER_PORT} -vvv | |
done | |
else | |
echo "Please install official GitHub CLI client." | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment