Fix error in creating logrotate onfiguration file.

This commit is contained in:
Christoph 2017-12-27 13:19:55 +01:00
parent 3d883a1cec
commit 397c78aa25

View File

@ -3596,16 +3596,16 @@ if [ ! -f "/etc/logrotate.d/apache2" ]; then
if ls /var/www/*/logs/php_errors.log > /dev/null 2>&1 ; then
chown ${HTTPD_USER}:${HTTPD_GROUP} /var/www/*/logs/php_errors.log
fi
if [[ -f "/var/log/apache2/php_errors.log" ]] ; then
if [ -f "/var/log/apache2/php_errors.log" ] ; then
chown ${HTTPD_USER}:${HTTPD_GROUP} /var/log/apache2/php_errors.log
fi
if [[ -x "/usr/local/apache2/bin/apachectl" ]]; then
if [ -x "/usr/local/apache2/bin/apachectl" ]; then
APACHECTL="/usr/local/apache2/bin/apachectl"
else
APACHECTL="\$(which apachectl)"
fi
if [[ -z "\$APACHECTL" ]] ; then
if [[ -f "/etc/init.d/apache2" ]; then
if [ -z "\$APACHECTL" ] ; then
if [ -f "/etc/init.d/apache2" ]; then
/etc/init.d/apache2 reload > /dev/null
else
echo "Reloading apache service failed!"