Don't use 'which' in the 'prepare-dirs' script

refs #10417
This commit is contained in:
Gunnar Beutner 2015-11-06 17:39:18 +01:00
parent 3ded63a01c
commit 991bb0cd7e
2 changed files with 2 additions and 2 deletions

View File

@ -47,7 +47,7 @@ fi
mkdir -p $ICINGA2_RUN_DIR/icinga2/cmd
chown $ICINGA2_USER:$ICINGA2_COMMAND_GROUP $ICINGA2_RUN_DIR/icinga2/cmd
if which restorecon >/dev/null 2&>1; then
if type restorecon >/dev/null 2&>1; then
restorecon -R $ICINGA2_RUN_DIR/icinga2/
fi
chmod 2750 $ICINGA2_RUN_DIR/icinga2/cmd

View File

@ -12,7 +12,7 @@ printf "Validating config files: "
OUTPUTFILE=`mktemp`
if env chcon >/dev/null 2&>1; then
if type chcon >/dev/null 2&>1; then
chcon -t icinga2_tmp_t $OUTPUTFILE
fi