view common/0logwatch @ 92:4412f5e0b2ba puppet-3.6

Add body checks to emails for the minority of obvious spam that aren't caught
author IBBoard <dev@ibboard.co.uk>
date Sat, 16 Jan 2016 11:01:09 +0000
parents 956e484adc12
children
line wrap: on
line source

#!/bin/bash

DailyReport=`grep -e "^[[:space:]]*DailyReport[[:space:]]*=[[:space:]]*" /usr/share/logwatch/default.conf/logwatch.conf | head -n1 | sed -e "s|^\s*DailyReport\s*=\s*||"`

if [ "$DailyReport" != "No" ] && [ "$DailyReport" != "no" ]
then
    logwatch
fi