From b47a51b89b54a9ba1f4c1d25f3b9262f5ca6ac0a Mon Sep 17 00:00:00 2001 From: qtwrk Date: Tue, 28 Jan 2020 18:26:00 +0100 Subject: [PATCH 1/3] fix lsphp74-zip --- cyberpanel.sh | 9 +++++++++ cyberpanel_upgrade.sh | 7 +++++++ 2 files changed, 16 insertions(+) diff --git a/cyberpanel.sh b/cyberpanel.sh index dba92f08d..811e5b364 100644 --- a/cyberpanel.sh +++ b/cyberpanel.sh @@ -1283,6 +1283,15 @@ watchdog_setup install_utility +if [[ ! -f /usr/local/lsws/lsphp74/lib64/php/modules/zip.so ]] ; then + yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-0.11.2-6.el7.psychotic.x86_64.rpm + yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-devel-0.11.2-6.el7.psychotic.x86_64.rpm + /usr/local/lsws/lsphp74/bin/pecl install zip + echo "extension=zip.so" > /usr/local/lsws/lsphp74/etc/php.d/20-zip.ini +fi +#fix the lsphp74-zip missing issue. + + clear echo "###################################################################" echo " CyberPanel Successfully Installed " diff --git a/cyberpanel_upgrade.sh b/cyberpanel_upgrade.sh index 0dcc91b37..34eb3628f 100644 --- a/cyberpanel_upgrade.sh +++ b/cyberpanel_upgrade.sh @@ -165,6 +165,13 @@ fi install_utility +if [[ ! -f /usr/local/lsws/lsphp74/lib64/php/modules/zip.so ]] ; then + yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-0.11.2-6.el7.psychotic.x86_64.rpm + yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-devel-0.11.2-6.el7.psychotic.x86_64.rpm + /usr/local/lsws/lsphp74/bin/pecl install zip + echo "extension=zip.so" > /usr/local/lsws/lsphp74/etc/php.d/20-zip.ini +fi +#fix the lsphp74-zip missing issue. ## From cdeacd1559a3da5b7963c3213ca27357bf94eb37 Mon Sep 17 00:00:00 2001 From: qtwrk Date: Tue, 28 Jan 2020 18:31:54 +0100 Subject: [PATCH 2/3] lsphp74 for centos 7 --- cyberpanel.sh | 2 +- cyberpanel_upgrade.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cyberpanel.sh b/cyberpanel.sh index 811e5b364..0be69c609 100644 --- a/cyberpanel.sh +++ b/cyberpanel.sh @@ -1283,7 +1283,7 @@ watchdog_setup install_utility -if [[ ! -f /usr/local/lsws/lsphp74/lib64/php/modules/zip.so ]] ; then +if [[ ! -f /usr/local/lsws/lsphp74/lib64/php/modules/zip.so ]] && [[ $SERVER_OS == "CentOS" ]] && [[ $CENTOS_8 == "False" ]]; then yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-0.11.2-6.el7.psychotic.x86_64.rpm yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-devel-0.11.2-6.el7.psychotic.x86_64.rpm /usr/local/lsws/lsphp74/bin/pecl install zip diff --git a/cyberpanel_upgrade.sh b/cyberpanel_upgrade.sh index 34eb3628f..60466074f 100644 --- a/cyberpanel_upgrade.sh +++ b/cyberpanel_upgrade.sh @@ -165,7 +165,7 @@ fi install_utility -if [[ ! -f /usr/local/lsws/lsphp74/lib64/php/modules/zip.so ]] ; then +if [[ ! -f /usr/local/lsws/lsphp74/lib64/php/modules/zip.so ]] && [[ $SERVER_OS == "CentOS7" ]] ; then yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-0.11.2-6.el7.psychotic.x86_64.rpm yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-devel-0.11.2-6.el7.psychotic.x86_64.rpm /usr/local/lsws/lsphp74/bin/pecl install zip From ab17c122c659e87361f55274f89e68da381b46a3 Mon Sep 17 00:00:00 2001 From: qtwrk Date: Tue, 28 Jan 2020 19:09:36 +0100 Subject: [PATCH 3/3] set permission for .so to match other modules file --- cyberpanel.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cyberpanel.sh b/cyberpanel.sh index 0be69c609..7cfdae467 100644 --- a/cyberpanel.sh +++ b/cyberpanel.sh @@ -1206,6 +1206,7 @@ for version in $(ls /usr/local/lsws | grep lsphp); /usr/local/lsws/${version}/bin/pear config-set temp_dir /usr/local/lsws/${version}/tmp /usr/local/lsws/${version}/bin/pecl install timezonedb echo "extension=timezonedb.so" > /usr/local/lsws/${version}/etc/php.d/20-timezone.ini + chmod 755 /usr/local/lsws/${version}/lib64/php/modules/timezonedb.so sed -i 's|expose_php = On|expose_php = Off|g' $php_ini sed -i 's|mail.add_x_header = On|mail.add_x_header = Off|g' $php_ini sed -i 's|;session.save_path = "/tmp"|session.save_path = "/var/lib/php/session"|g' $php_ini @@ -1288,6 +1289,7 @@ if [[ ! -f /usr/local/lsws/lsphp74/lib64/php/modules/zip.so ]] && [[ $SERVER_OS yum install -y http://packages.psychotic.ninja/7/plus/x86_64/RPMS/libzip-devel-0.11.2-6.el7.psychotic.x86_64.rpm /usr/local/lsws/lsphp74/bin/pecl install zip echo "extension=zip.so" > /usr/local/lsws/lsphp74/etc/php.d/20-zip.ini + chmod 755 /usr/local/lsws/lsphp74/lib64/php/modules/zip.so fi #fix the lsphp74-zip missing issue.