Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

php版本升级 #708

Merged
merged 12 commits into from
Feb 18, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion plugins/php/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ def phpOp(version, method):


def start(version):
cmd = 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/www/server/lib/icu/lib:/opt/homebrew/lib'
cmd = 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/www/server/lib/icu/lib:/usr/lib/x86_64-linux-gnu/:/opt/homebrew/lib'
mw.execShell(cmd)
return phpOp(version, 'start')

Expand Down
39 changes: 39 additions & 0 deletions plugins/php/lib/imagemagick.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
#!/bin/bash
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin:/opt/homebrew/bin
export PATH

curPath=`pwd`
rootPath=$(dirname "$curPath")
rootPath=$(dirname "$rootPath")
rootPath=$(dirname "$rootPath")
rootPath=$(dirname "$rootPath")

igmVersion="7.1.1-15"
# echo $rootPath

SERVER_ROOT=$rootPath/lib
SOURCE_ROOT=$rootPath/source/lib

if [ ! -d ${SERVER_ROOT}/ImageMagick ];then
cd ${SOURCE_ROOT}
if [ ! -f ${SOURCE_ROOT}/ImageMagick-${igmVersion}.tar.gz ];then
wget --no-check-certificate -O ImageMagick-${igmVersion}.tar.gz https://imagemagick.org/archive/ImageMagick-${igmVersion}.tar.gz -T 20
fi

tar -zxf ImageMagick-${igmVersion}.tar.gz
cd ImageMagick-${igmVersion}
./configure --prefix=${SERVER_ROOT}/ImageMagick --disable-openmp
make && make install

if [ -d /etc/ld.so.conf.d ];then
echo "/www/server/lib/ImageMagick/lib" > /etc/ld.so.conf.d/ImageMagick.conf
elif [ -f /etc/ld.so.conf ]; then
echo "/www/server/lib/ImageMagick/lib" >> /etc/ld.so.conf
fi

ldconfig

cd $SOURCE_ROOT && rm -rf $SOURCE_ROOT/ImageMagick-${igmVersion}
fi


4 changes: 2 additions & 2 deletions plugins/php/versions/83/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ serverPath=$(dirname "$rootPath")
sourcePath=${serverPath}/source
sysName=`uname`

version=8.3.15
version=8.3.17
PHP_VER=83
Install_php()
{
Expand Down Expand Up @@ -50,7 +50,7 @@ if [ ! -d $sourcePath/php/php${PHP_VER} ];then
fi

#检测文件是否损坏.
md5_file_ok=3df5d45637283f759eef8fc3ce03de829ded3e200c3da278936a684955d2f94f
md5_file_ok=6158ee678e698395da13d72c7679a406d2b7554323432f14d37b60ed87d8ccfb
if [ -f $sourcePath/php/php-${version}.tar.xz ];then
md5_file=`sha256sum $sourcePath/php/php-${version}.tar.xz | awk '{print $1}'`
if [ "${md5_file}" != "${md5_file_ok}" ]; then
Expand Down
4 changes: 2 additions & 2 deletions plugins/php/versions/84/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ serverPath=$(dirname "$rootPath")
sourcePath=${serverPath}/source
sysName=`uname`

version=8.4.2
version=8.4.4
PHP_VER=84
Install_php()
{
Expand All @@ -35,7 +35,7 @@ if [ ! -d $sourcePath/php/php${PHP_VER} ];then
fi

#检测文件是否损坏.
# md5_file_ok=92636453210f7f2174d6ee6df17a5811368f556a6c2c2cbcf019321e36456e01
# md5_file_ok=05a6c9a2cc894dd8be719ecab221b311886d5e0c02cb6fac648dd9b3459681ac
# if [ -f $sourcePath/php/php-${version}.tar.xz ];then
# md5_file=`sha256sum $sourcePath/php/php-${version}.tar.xz | awk '{print $1}'`
# if [ "${md5_file}" != "${md5_file_ok}" ]; then
Expand Down
4 changes: 4 additions & 0 deletions plugins/php/versions/common/imagemagick.sh
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ Install_lib()
OPTIONS="$OPTIONS --build=aarch64-unknown-linux-gnu --host=aarch64-unknown-linux-gnu"
fi

# if [ "$version" -gt "74" ];then
# OPTIONS="$OPTIONS --disable-openmp"
# fi

$serverPath/php/$version/bin/phpize
./configure --with-php-config=$serverPath/php/$version/bin/php-config $OPTIONS
make clean && make && make install && make clean
Expand Down
4 changes: 2 additions & 2 deletions plugins/phpmyadmin/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ Install_phpmyadmin()
fi

mkdir -p ${serverPath}/source/phpmyadmin
echo "${1}" > ${serverPath}/phpmyadmin/version.pl

VER=$1

Expand All @@ -66,7 +65,8 @@ Install_phpmyadmin()
cp -r $serverPath/source/phpmyadmin/$FDIR $serverPath/phpmyadmin/
cd $serverPath/phpmyadmin/ && mv $FDIR phpmyadmin
rm -rf $serverPath/source/phpmyadmin/$FDIR


echo "${1}" > ${serverPath}/phpmyadmin/version.pl
cd ${rootPath} && python3 ${rootPath}/plugins/phpmyadmin/index.py start

echo '安装完成'
Expand Down
1 change: 0 additions & 1 deletion plugins/tgbot/startup/extend/push_ad.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ def send_msg(bot, tag='ad', trigger_time=300):
# 信号只在一个周期内执行一次|end

# 跨链混币器Cce.Cash💰低手续费💰隔断溯源 | 10/m | next,6/10 | @hu ge
# TTKCDN 无视移动墙/GFW/SNI阻断 TG第一性价比 | 10/m | @ssdpflood
# SJ资源网播放计费| 14/m | next,4/14 |@sjllzyw
# https://t.me/gjgzs2022 | 22/m | @GJ_gzs
# 综合包网/NG接口开户 | 28/m | 6m | next,4/28 | x
Expand Down
1 change: 0 additions & 1 deletion plugins/tgbot/startup/extend/push_notice_msg.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ def send_msg(bot, tag='ad', trigger_time=300):
# 信号只在一个周期内执行一次|end

# 跨链混币器Cce.Cash💰低手续费💰隔断溯源 | 10/m | next,6/10 | @hu ge
# TTKCDN | 10/m | @ssdpflood | 5
# SJ资源网播放计费| 14/m | next,4/14 |@sjllzyw
# https://t.me/gjgzs2022 | 22/m | @GJ_gzs
# 综合包网/NG接口开户 | 28/m | 6m | next,4/28 | x
Expand Down
3 changes: 2 additions & 1 deletion scripts/install/debian.sh
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,8 @@ apt install -y libargon2-dev

apt install -y libmemcached-dev
apt install -y libsasl2-dev
apt install -y imagemagick
apt install -y imagemagick
apt install -y libmagickcore-dev
apt install -y libmagickwand-dev

apt install -y libxml2 libxml2-dev libbz2-dev libmcrypt-dev libpspell-dev librecode-dev
Expand Down
3 changes: 2 additions & 1 deletion scripts/install/ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,8 @@ apt install -y libargon2-dev

apt install -y libmemcached-dev
apt install -y libsasl2-dev
apt install -y imagemagick
apt install -y imagemagick
apt install -y libmagickcore-dev
apt install -y libmagickwand-dev

apt install -y libxml2 libxml2-dev libbz2-dev libmcrypt-dev libpspell-dev librecode-dev
Expand Down