This commit is contained in:
parent
5329050a10
commit
3b783daa18
|
|
@ -9,14 +9,17 @@ serverPath=$(dirname "$rootPath")
|
|||
|
||||
install_tmp=${rootPath}/tmp/bt_install.pl
|
||||
|
||||
|
||||
CSVN_SOURCE='https://github.com/midoks/mdserver-web/releases/download/init/CollabNetSubversionEdge-5.1.4_linux-x86_64.tar.xz'
|
||||
|
||||
Install_csvn()
|
||||
{
|
||||
mkdir -p $serverPath/tmp
|
||||
|
||||
echo '正在安装脚本文件...' > $install_tmp
|
||||
|
||||
if [ ! -d $serverPath/tmp/csvn.tar.xz ];then
|
||||
wget -O $serverPath/tmp/csvn.tar.xz https://github.com/midoks/mdserver-web/releases/download/init/CollabNetSubversionEdge-5.1.4_linux-x86_64.tar.xz
|
||||
if [ ! -f $serverPath/tmp/csvn.tar.xz ];then
|
||||
wget -O $serverPath/so/csvn.tar.xz ${CSVN_SOURCE}
|
||||
fi
|
||||
|
||||
cd $serverPath/tmp && tar -Jxf $serverPath/tmp/csvn.tar.xz
|
||||
|
|
|
|||
|
|
@ -5,8 +5,8 @@
|
|||
"name": "php",
|
||||
"title": "PHP",
|
||||
"default": false,
|
||||
"versions": ["5.2","7.2"],
|
||||
"updates": ["5.2.17p1","7.2.0"],
|
||||
"versions": ["52","72"],
|
||||
"updates": ["5.2.17","7.2.0"],
|
||||
"tip": "soft",
|
||||
"checks": "server/php/VERSION/bin/php",
|
||||
"display": 1,
|
||||
|
|
|
|||
|
|
@ -23,4 +23,4 @@ if [ ! -d $curPath/versions/$2 ];then
|
|||
exit 0
|
||||
fi
|
||||
|
||||
. $curPath/versions/$2/install.sh $1
|
||||
sh -x $curPath/versions/$2/install.sh $1
|
||||
|
|
|
|||
|
|
@ -1,14 +0,0 @@
|
|||
#!/bin/bash
|
||||
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin
|
||||
export PATH
|
||||
|
||||
curPath=`pwd`
|
||||
rootPath=$(dirname "$curPath")
|
||||
rootPath=$(dirname "$rootPath")
|
||||
serverPath=$(dirname "$rootPath")
|
||||
|
||||
|
||||
install_tmp=${rootPath}/tmp/bt_install.pl
|
||||
|
||||
echo $curPath
|
||||
echo ${1}
|
||||
|
|
@ -0,0 +1,65 @@
|
|||
#!/bin/bash
|
||||
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin
|
||||
export PATH
|
||||
|
||||
curPath=`pwd`
|
||||
rootPath=$(dirname "$curPath")
|
||||
rootPath=$(dirname "$rootPath")
|
||||
serverPath=$(dirname "$rootPath")
|
||||
sourcePath=${serverPath}/source
|
||||
|
||||
install_tmp=${rootPath}/tmp/bt_install.pl
|
||||
|
||||
# echo $curPath
|
||||
# echo ${1}
|
||||
# echo ${serverPath}
|
||||
# echo ${install_tmp}
|
||||
|
||||
|
||||
Install_php()
|
||||
{
|
||||
#------------------------ install start ------------------------------------#
|
||||
echo "安装php-5.2.17 ..." > $install_tmp
|
||||
mkdir -p $sourcePath/php
|
||||
mkdir -p $serverPath/php
|
||||
|
||||
if [ ! -f $sourcePath/php/php-5.2.17.tar.bz2 ];then
|
||||
wget -O $sourcePath/php/php-5.2.17.tar.bz2 https://museum.php.net/php5/php-5.2.17.tar.bz2
|
||||
fi
|
||||
|
||||
if [ ! -d $sourcePath/php/php-5.2.17 ];then
|
||||
cd $sourcePath/php && tar -Jxf $sourcePath/php/php-5.2.17.tar.bz2
|
||||
fi
|
||||
|
||||
|
||||
cd $sourcePath/php/php-5.2.17 && ./configure \
|
||||
--prefix=$serverPath/php/php52 \
|
||||
--exec-prefix=$serverPath/php/php52 \
|
||||
--with-config-file-path=$serverPath/php/php55/etc \
|
||||
--with-zlib-dir=$serverPath/lib/zlib \
|
||||
--without-iconv \
|
||||
--enable-zip \
|
||||
--enable-mbstring \
|
||||
--enable-ftp \
|
||||
--enable-wddx \
|
||||
--enable-soap \
|
||||
--enable-posix \
|
||||
--enable-fpm \
|
||||
&& make && make install
|
||||
|
||||
#------------------------ install end ------------------------------------#
|
||||
}
|
||||
|
||||
|
||||
|
||||
Uninstall_php()
|
||||
{
|
||||
echo "卸载php-5.2.17 ..." > $install_tmp
|
||||
}
|
||||
|
||||
action=${1}
|
||||
if [ "${1}" == 'install' ];then
|
||||
Install_php
|
||||
else
|
||||
Uninstall_php
|
||||
fi
|
||||
|
|
@ -4,31 +4,27 @@ PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin
|
|||
curPath=`pwd`
|
||||
rootPath=$(dirname "$curPath")
|
||||
serverPath=$(dirname "$rootPath")
|
||||
tmpPath=$serverPath/tmp
|
||||
sourcePath=$serverPath/source/lib
|
||||
libPath=$serverPath/lib
|
||||
|
||||
mkdir -p $sourcePath
|
||||
mkdir -p $libPath
|
||||
rm -rf ${libPath}/lib.pl
|
||||
|
||||
|
||||
Install_Curl()
|
||||
Install_Zlib()
|
||||
{
|
||||
if [ -f "/usr/local/curl/newcurl.pl" ];then
|
||||
return;
|
||||
fi
|
||||
cd ${run_path}
|
||||
curl_version="7.54.1"
|
||||
if [ ! -f "curl-$curl_version.tar.gz" ];then
|
||||
wget -O curl-$curl_version.tar.gz ${download_Url}/src/curl-$curl_version.tar.gz -T 5
|
||||
fi
|
||||
tar zxf curl-$curl_version.tar.gz
|
||||
cd curl-$curl_version
|
||||
./configure --prefix=/usr/local/curl --enable-ares --without-nss --with-ssl=/usr/local/openssl
|
||||
make && make install
|
||||
cd ..
|
||||
rm -rf curl-$curl_version
|
||||
rm -rf curl-$curl_version.tar.gz
|
||||
echo -e "Install_Curl" >> /www/server/lib.pl
|
||||
echo -e "Ture" >> /usr/local/curl/newcurl.pl
|
||||
#----------------------------- zlib start -------------------------#
|
||||
if [ ! -d ${libPath}/zlib ];then
|
||||
cd ${sourcePath}
|
||||
if [ ! -f ${sourcePath}/zlib-1.2.11.tar.gz ];then
|
||||
wget -O zlib-1.2.11.tar.gz https://github.com/madler/zlib/archive/v1.2.11.tar.gz -T 20
|
||||
fi
|
||||
tar -zxf zlib-1.2.11.tar.gz
|
||||
cd zlib-1.2.11
|
||||
./configure --prefix=${libPath}/zlib && make && make install
|
||||
fi
|
||||
echo -e "Install_Zlib" >> ${libPath}/lib.pl
|
||||
#----------------------------- zlib end -------------------------#
|
||||
}
|
||||
|
||||
Install_Libiconv()
|
||||
|
|
@ -175,8 +171,8 @@ Install_Pcre()
|
|||
Install_OpenSSL()
|
||||
{
|
||||
if [ ! -d ${libPath}/openssl ];then
|
||||
cd ${tmpPath}
|
||||
if [ ! -d ${tmpPath}openssl-1.0.2q.tar.gz ];then
|
||||
cd ${sourcePath}
|
||||
if [ ! -f ${sourcePath}openssl-1.0.2q.tar.gz ];then
|
||||
wget https://github.com/midoks/mdserver-web/releases/download/init/openssl-1.0.2q.tar.gz -T 20
|
||||
fi
|
||||
tar -zxf openssl-1.0.2q.tar.gz
|
||||
|
|
@ -184,7 +180,9 @@ Install_OpenSSL()
|
|||
./config --openssldir=${libPath}/openssl zlib-dynamic shared
|
||||
make && make install
|
||||
fi
|
||||
echo -e "Install_OpenSSL" >> ${libPath}/lib.pl
|
||||
}
|
||||
|
||||
Install_Lib()
|
||||
{
|
||||
if [ -f "/www/server/nginx/sbin/nginx" ] || [ -f "/www/server/apache/bin/httpd" ] || [ -f "/www/server/mysql/bin/mysql" ]; then
|
||||
|
|
@ -207,11 +205,10 @@ if [ ! -f "${lockFile}" ];then
|
|||
fi
|
||||
}
|
||||
|
||||
|
||||
Install_Zlib
|
||||
# Install_Lib
|
||||
Install_OpenSSL
|
||||
# Install_Pcre
|
||||
# Install_Curl
|
||||
# Install_Mhash
|
||||
# Install_Libmcrypt
|
||||
# Install_Mcrypt
|
||||
|
|
|
|||
Loading…
Reference in New Issue