From d7f3d48d369c34da3dffbe1c005be4712cab9aa6 Mon Sep 17 00:00:00 2001 From: myvesta <38690722+myvesta@users.noreply.github.com> Date: Fri, 26 Feb 2021 01:18:06 +0100 Subject: [PATCH] Update postinst --- src/deb/vesta/postinst | 32 ++------------------------------ 1 file changed, 2 insertions(+), 30 deletions(-) diff --git a/src/deb/vesta/postinst b/src/deb/vesta/postinst index be9d932b1..acf137098 100755 --- a/src/deb/vesta/postinst +++ b/src/deb/vesta/postinst @@ -133,8 +133,8 @@ if [ ! -f "/usr/local/vesta/data/upgrades/change-clamav-socket-v4" ]; then fi # Making sure mpm_event will stay -if [ ! -f "/usr/local/vesta/data/upgrades/keeping-mpm-event" ]; then - touch /usr/local/vesta/data/upgrades/keeping-mpm-event +if [ ! -f "/usr/local/vesta/data/upgrades/keeping-mpm-event-2" ]; then + touch /usr/local/vesta/data/upgrades/keeping-mpm-event-2 echo "=== scheduling keeping-mpm-event check script" echo "bash /usr/local/vesta/upd/keep_mpm_event.sh 'background' >> /usr/local/vesta/data/upgrades/keeping-mpm-event.log 2>&1" >> /usr/local/vesta/data/queue/restart.pipe /usr/local/vesta/bin/v-add-cron-restart-job > /dev/null 2>&1 @@ -218,34 +218,6 @@ if [ ! -f "/usr/local/vesta/data/upgrades/apache_status_public_access" ]; then fi fi -# Making sure Apache is in mpm_event mode -if [ ! -f "/usr/local/vesta/data/upgrades/apache_in_mpm_mode" ]; then - touch /usr/local/vesta/data/upgrades/apache_in_mpm_mode - - check_grep=$(grep -c "WEB_SYSTEM='nginx'" /usr/local/vesta/conf/vesta.conf) - if [ "$check_grep" -eq 0 ]; then - if [ $release -eq 10 ]; then - if [ -f "/etc/apt/sources.list.d/php.list" ]; then - echo "=== Making sure Apache is in mpm_event mode" - a2dismod ruid2 > /dev/null 2>&1 - a2dismod suexec > /dev/null 2>&1 - a2dismod php5.6 > /dev/null 2>&1 - a2dismod php7.0 > /dev/null 2>&1 - a2dismod php7.1 > /dev/null 2>&1 - a2dismod php7.2 > /dev/null 2>&1 - a2dismod php7.3 > /dev/null 2>&1 - a2dismod php7.4 > /dev/null 2>&1 - a2dismod php8.0 > /dev/null 2>&1 - a2dismod mpm_prefork > /dev/null 2>&1 - a2enmod mpm_event > /dev/null 2>&1 - apt-get -y remove libapache2-mod-php7.4 > /dev/null 2>&1 - apt-get -y remove libapache2-mod-php8.0 > /dev/null 2>&1 - service apache2 restart - fi - fi - fi -fi - # Run custom triggers if [ -x "/root/vesta-patch.sh" ]; then /root/vesta-patch.sh