From: Michal Sojka Date: Sat, 6 Dec 2014 22:44:02 +0000 (+0100) Subject: Do not send emails from every cron job X-Git-Tag: pc-sw-update~3 X-Git-Url: http://rtime.felk.cvut.cz/gitweb/can-benchmark.git/commitdiff_plain/6085399f090910390214e52cf2a9a6ed049fa9fa Do not send emails from every cron job Send them only when glab cannot boot within 2 minutes. --- diff --git a/continuous/cron.sh b/continuous/cron.sh index a7794cd..a65b9aa 100755 --- a/continuous/cron.sh +++ b/continuous/cron.sh @@ -8,7 +8,7 @@ cd $(dirname $0) # Wakeup glab sudo /usr/sbin/etherwake 00:0c:f1:77:ec:46 -while ! ssh sojka@glab true; do sleep 1; done +chronic timeout 2m sh -c 'while ! ssh sojka@glab true; do sleep 1; done' sleep 30 # Wait a bit to finish all boot jobs etc. mkdir -p logs