|
|
|
@ -22,12 +22,12 @@ if [ "$(id -u)" != '0' ]; then
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
php_DIR="/run/php"
|
|
|
|
|
#make php directory in /var/run/directory for php-fpm
|
|
|
|
|
#make php directory in /var/run/directory for php-fpm and for hestia-php
|
|
|
|
|
if [ -f /etc/redhat-release ]; then
|
|
|
|
|
user_apache=$(cat $HESTIA_INSTALL_DIR/php-fpm/multiphp.tpl | grep listen.group | cut -d= -f2 | xargs)
|
|
|
|
|
if [ -n "$user_apache" ]; then
|
|
|
|
|
if grep "$user_apache" /etc/passwd; then
|
|
|
|
|
if grep "$user_apache" /etc/group; then
|
|
|
|
|
if grep -q "$user_apache" /etc/passwd; then
|
|
|
|
|
if grep -q "$user_apache" /etc/group; then
|
|
|
|
|
if [ ! -e "$php_DIR" ]; then
|
|
|
|
|
mkdir "$php_DIR"
|
|
|
|
|
chmod 755 "$php_DIR"
|
|
|
|
@ -36,4 +36,13 @@ if [ -f /etc/redhat-release ]; then
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
if [ ! -e /run/hestia ]; then
|
|
|
|
|
mkdir /run/hestia
|
|
|
|
|
chown admin:admin /run/hestia
|
|
|
|
|
else
|
|
|
|
|
own=$(stat -c "%U:%G" /run/hestia)
|
|
|
|
|
if [ "$own" != "admin:admin" ]; then
|
|
|
|
|
chown admin:admin /run/hestia
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
fi
|