BF: Assure that /var/run/fail2ban exists upon start (LP: #222804, #223706)

pull/3/head
Yaroslav Halchenko 2008-05-06 10:43:57 -04:00
parent 8207f166e1
commit 32281ed1aa
1 changed files with 3 additions and 0 deletions

View File

@ -100,6 +100,9 @@ do_start()
DAEMON_ARGS="$DAEMON_ARGS -x"
fi
# Assure that /var/run/fail2ban exists
[ -d /var/run/fail2ban ] || mkdir -p /var/run/fail2ban
start-stop-daemon --start --quiet --chuid root --exec $DAEMON -- \
$DAEMON_ARGS start > /dev/null\
|| return 2