mdserver-web/plugins/php/install.sh

27 lines
492 B
Bash
Raw Permalink Normal View History

2018-10-07 06:51:52 -04:00
#!/bin/bash
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin
export PATH
2018-11-26 00:57:06 -05:00
curPath=`pwd`
rootPath=$(dirname "$curPath")
rootPath=$(dirname "$rootPath")
serverPath=$(dirname "$rootPath")
install_tmp=${rootPath}/tmp/bt_install.pl
2018-10-07 06:51:52 -04:00
2018-11-27 00:17:06 -05:00
action=$1
type=$2
2018-10-07 06:51:52 -04:00
2018-11-27 00:17:06 -05:00
if [ "${2}" == "" ];then
echo '缺少安装脚本...' > $install_tmp
exit 0
fi
2018-10-07 06:51:52 -04:00
2018-11-27 00:17:06 -05:00
if [ ! -d $curPath/versions/$2 ];then
echo '缺少安装脚本2...' > $install_tmp
2018-11-27 01:37:24 -05:00
exit 0
2018-10-07 06:51:52 -04:00
fi
2018-11-27 00:17:06 -05:00
2018-11-27 06:20:46 -05:00
sh -x $curPath/versions/$2/install.sh $1