Attempt to use autossh

This commit is contained in:
mathias 2019-09-03 01:54:19 +03:00
parent 814dc757db
commit bbe4062c5f
2 changed files with 3 additions and 5 deletions

View file

@ -1,5 +1,5 @@
#!/bin/sh
PATH="$HOME/java/bin/:$HOME/tmux/bin/:$PATH"
PATH="$HOME/autossh/bin/:$HOME/java/bin/:$HOME/tmux/bin/:$PATH"
echo "$REMOTE_KEY" > .ssh/remote
echo "$SYNC_KEY" > .ssh/id_rsa

View file

@ -1,5 +1,3 @@
#!/bin/sh
while true; do
ssh -i ~/.ssh/remote -o StrictHostKeyChecking=no -o ExitOnForwardFailure=yes -o StreamLocalBindUnlink=yes -c aes128-ctr -C -S none -N -T -R 53950:localhost:25565 -p 53940 remote@play.kaboom.pw
sleep 1
done
export AUTOSSH_POLL=30
autossh -M 53941 -i ~/.ssh/remote -o StrictHostKeyChecking=no -o ExitOnForwardFailure=yes -o StreamLocalBindUnlink=yes -c aes128-ctr -C -S none -N -T -R 53950:localhost:25565 -p 53940 remote@play.kaboom.pw