Add directive for Mutes.

This commit is contained in:
Christoph 2019-07-12 01:09:04 +02:00
parent 4c97970d0d
commit 034d7f919e

View File

@ -94,6 +94,8 @@ _START_AT_BOOTTIME=yes
APACHE_LOG_DIR=/var/log/apache2
DIRECTORY_INDEX="index.html index.htm index.php"
MUTEX_DIR="${APACHE_LOG_DIR}/ssl_mutex"
_BASE_WEBSPACE_DIR="/var/www"
#_GLOBAL_DOC_ROOT="${_BASE_WEBSPACE_DIR}/default"
#_SUEXEC_DOC_ROOT=$_BASE_WEBSPACE_DIR
@ -2023,6 +2025,41 @@ if [ -f $_httpdconf ];then
else
echo_failed
fi
## - Create Mutex Directory
## -
echo "" >> ${_logdir}/main.log
echo "## - Create $MUTEX_DIR\" (if not exists).." >> ${_logdir}/main.log
echo "## -" >> ${_logdir}/main.log
echo "mkdir -p $MUTEX_DIR" >> ${_logdir}/main.log
echononl "\tCreate $MUTEX_DIR\" (if not exists).."
if [[ ! -d "$MUTEX_DIR" ]]; then
mkdir -p $MUTEX_DIR >> ${_logdir}/main.log 2>&1
if [[ $? -eq 0 ]]; then
echo_ok
else
echo_failed
fi
else
echo_skipped
fi
echo "" >> ${_logdir}/main.log
echo "## - Change ownership of '$MUTEX_DIR' to '$HTTPD_USER'.."
echo "## -" >> ${_logdir}/main.log
echo "chown $HTTPD_USER $MUTEX_DIR" >> ${_logdir}/main.log
echononl "\tChange ownership of '$MUTEX_DIR' to '$HTTPD_USER'.."
if [[ "$(stat -c '%U' /var/log/apache2/ssl_mutex)" != "$HTTPD_USER" ]]; then
chown $HTTPD_USER $MUTEX_DIR >> ${_logdir}/main.log 2>&1
if [[ $? -eq 0 ]]; then
echo_ok
else
echo_failed
fi
else
echo_skipped
fi
fi
echo "" >> ${_logdir}/main.log
@ -3573,6 +3610,11 @@ EOF
fi
cat <<EOF >> ${PREFIX}/conf/vhosts/000-default.conf
## - Configures mutex mechanism and lock file directory for all or specified mutexes.
## - Specify 'default' as the second argument to change the settings for all mutexes.
## -
Mutex file:/var/log/apache2/ssl_mutex default
SSLCompression off
SSLStrictSNIVHostCheck off