From e0fa7c97cebb9b9be1c85975f9ab78922b8c4c6a Mon Sep 17 00:00:00 2001 From: Mathieu Maret Date: Wed, 29 Oct 2014 17:40:28 +0100 Subject: [PATCH] [script]use autossh for setBridge --- scripts/setBrigde.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/setBrigde.sh b/scripts/setBrigde.sh index ede5d39..0c2508f 100755 --- a/scripts/setBrigde.sh +++ b/scripts/setBrigde.sh @@ -1,8 +1,8 @@ #!/bin/bash user=pi host=tutabaga.hd.free.fr -ps aux | grep ssh | grep $host > /dev/null +ps aux | grep autossh | grep $host > /dev/null res=$? if [ $res == 1 ]; then - ssh -N -R 65022:localhost:22 $user@$host& + autossh -M 2222 -f -N -R 65022:localhost:22 $user@$host fi