aboutsummaryrefslogtreecommitdiff
path: root/modules/profile/files/monitoring/check_last_file_date
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2018-07-12 08:51:22 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2018-07-12 08:51:22 +0200
commitde68b72374231be37df7c171596672a21a218958 (patch)
tree96b09b188872a5d48385da467ea4a5990aeb90b0 /modules/profile/files/monitoring/check_last_file_date
parent21d531ee2e4a5952673d694342ff01822581a1f8 (diff)
parent96f8d0f037f8b8e93315e864bdaf661f45e3c472 (diff)
downloadPuppet-de68b72374231be37df7c171596672a21a218958.tar.gz
Puppet-de68b72374231be37df7c171596672a21a218958.tar.zst
Puppet-de68b72374231be37df7c171596672a21a218958.zip
Merge branch 'monitoring' into dev
Diffstat (limited to 'modules/profile/files/monitoring/check_last_file_date')
-rw-r--r--modules/profile/files/monitoring/check_last_file_date4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/profile/files/monitoring/check_last_file_date b/modules/profile/files/monitoring/check_last_file_date
index 8eabb57..d520a84 100644
--- a/modules/profile/files/monitoring/check_last_file_date
+++ b/modules/profile/files/monitoring/check_last_file_date
@@ -22,10 +22,10 @@ else
22 LC_ALL=C last_date=$(printf "%.*f" 0 $last_date) 22 LC_ALL=C last_date=$(printf "%.*f" 0 $last_date)
23 min_date=$(date -d "$hours hours ago" "+%s") 23 min_date=$(date -d "$hours hours ago" "+%s")
24 if [ "$min_date" -lt "$last_date" ]; then 24 if [ "$min_date" -lt "$last_date" ]; then
25 echo "OK: Last backup $(date -d @$last_date)" 25 echo "OK: Last file $(date -d @$last_date)"
26 exit $STATE_OK 26 exit $STATE_OK
27 else 27 else
28 echo "CRITICAL: Last backup $(date -d @$last_date)" 28 echo "CRITICAL: Last file $(date -d @$last_date)"
29 exit $STATE_CRITICAL 29 exit $STATE_CRITICAL
30 fi 30 fi
31fi 31fi