Do not remove failed cache file on Nagios mode

This commit is contained in:
Benjamin Renard 2014-12-31 10:50:29 +01:00
parent c9d8cb8e2f
commit b3db96780c
1 changed files with 1 additions and 1 deletions

View File

@ -83,7 +83,7 @@ do
if [ -n "$newest" ]
then
[ $DEBUG -eq 1 ] && echo "Newest : $newest"
rm -f $CACHE_FAILED > /dev/null 2>&1
[ $NAGIOS -ne 1 ] && rm -f $CACHE_FAILED > /dev/null 2>&1
DOWNLOAD_URL=`cat $tmpfile|grep "$newest"|grep "tar.gz"|head -1|sed 's/.* href="[ \t]*\([^"]*\)[ \t]*" .*$/\1/'`
[ $DEBUG -eq 1 ] && echo "Download URL : $DOWNLOAD_URL"