1 Star 1 Fork 0

摩天大少 / lnmpx

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
customer.sh 20.29 KB
一键复制 编辑 原始数据 按行查看 历史
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764
#!/bin/bash
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin
export PATH
# Check if user is root
if [ $(id -u) != "0" ]; then
echo "Error: You must be root to run this script, please use root to install lnmp"
exit 1
fi
cur_dir=$(pwd)
Stack=$1
if [ "${Stack}" = "" ]; then
Stack="lnmp"
else
Stack=$1
fi
LNMP_Ver='1.3'
. lnmp.conf
. include/main.sh
. include/init.sh
. include/mysql.sh
. include/mariadb.sh
. include/php.sh
. include/nginx.sh
. include/apache.sh
. include/end.sh
Get_Dist_Name
if [ "${DISTRO}" = "unknow" ]; then
Echo_Red "Unable to get Linux distribution name, or do NOT support the current distribution."
exit 1
fi
clear
echo "+------------------------------------------------------------------------+"
echo "| LNMP V${LNMP_Ver} for ${DISTRO} Linux Server, Written by Licess |"
echo "+------------------------------------------------------------------------+"
echo "| A tool to auto-compile & install LNMP/LNMPA/LAMP on Linux |"
echo "+------------------------------------------------------------------------+"
echo "| For more information please visit http://www.lnmp.org |"
echo "+------------------------------------------------------------------------+"
#------------------------- start customer methods start -------------------------------------------------
Check_LAP_Install()
{
Check_PHP_Files
Check_Apache_Files
if [[ "${isPHP}" = "ok" && "${isApache}" = "ok" ]]; then
Print_Sucess_Info
else
Print_Failed_Info
fi
}
Check_LNP_Install()
{
Check_Nginx_Files
Check_PHP_Files
if [[ "${isNginx}" = "ok" && "${isPHP}" = "ok" ]]; then
Print_Sucess_Info
else
Print_Failed_Info
fi
}
Check_LM_Install()
{
Check_DB_Files
if [ "${isDB}" = "ok" ]; then
Print_Sucess_Info
else
Print_Failed_Info
fi
}
Check_LN_Install()
{
Check_Nginx_Files
if [ "${isNginx}" = "ok" ]; then
Print_Sucess_Info
else
Print_Failed_Info
fi
}
Restart_PHP()
{
if [ -s /usr/local/apache/bin/httpd ] && [ -s /usr/local/apache/conf/httpd.conf ] && [ -s /etc/init.d/httpd ]; then
echo "Restarting Apache......"
/etc/init.d/httpd restart
else
echo "Restarting php-fpm......"
/etc/init.d/php-fpm restart
fi
}
Add_LAP_Startup()
{
StartUp httpd
/etc/init.d/httpd start
}
Add_LNP_Startup(){
echo "Add Startup and Starting LNP..."
\cp ${cur_dir}/conf/lnmp /bin/lnmp
chmod +x /bin/lnmp
StartUp nginx
/etc/init.d/nginx start
StartUp php-fpm
/etc/init.d/php-fpm start
if [ "${PHPSelect}" = "1" ]; then
sed -i 's#/usr/local/php/var/run/php-fpm.pid#/usr/local/php/logs/php-fpm.pid#' /bin/lnmp
fi
}
Add_LN_Startup()
{
StartUp nginx
/etc/init.d/nginx start
}
Add_LM_Startup()
{
if [[ "${DBSelect}" = "4" || "${DBSelect}" = "5" ]]; then
StartUp mariadb
/etc/init.d/mariadb start
sed -i 's#/etc/init.d/mysql#/etc/init.d/mariadb#' /bin/lnmp
else
StartUp mysql
/etc/init.d/mysql start
fi
}
Install_Nginx_Only()
{
Echo_Blue "[+] Installing ${Nginx_Ver}... "
groupadd www
useradd -s /sbin/nologin -g www www
Tar_Cd ${Nginx_Ver}.tar.gz ${Nginx_Ver}
if echo ${Nginx_Ver} | grep -Eqi 'nginx-[0-1].[5-8].[0-9]' || echo ${Nginx_Ver} | grep -Eqi 'nginx-1.9.[1-4]$'; then
./configure --user=www --group=www --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-http_spdy_module --with-http_gzip_static_module --with-ipv6 --with-http_sub_module ${NginxMAOpt} ${Nginx_Modules_Options}
else
./configure --user=www --group=www --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-http_v2_module --with-http_gzip_static_module --with-ipv6 --with-http_sub_module ${NginxMAOpt} ${Nginx_Modules_Options}
fi
make && make install
cd ../
ln -sf /usr/local/nginx/sbin/nginx /usr/bin/nginx
rm -f /usr/local/nginx/conf/nginx.conf
cd ${cur_dir}
\cp conf/nginx.conf /usr/local/nginx/conf/nginx.conf
sed -i 'include enable-php.conf;/d' /usr/local/nginx/conf/nginx.conf
\cp conf/rewrite/dabr.conf /usr/local/nginx/conf/dabr.conf
\cp conf/rewrite/none.conf /usr/local/nginx/conf/none.conf
\cp conf/pathinfo.conf /usr/local/nginx/conf/pathinfo.conf
\cp conf/enable-ssl-example.conf /usr/local/nginx/conf/enable-ssl-example.conf
mkdir -p ${Default_Website_Dir}
chmod +w ${Default_Website_Dir}
mkdir -p /home/wwwlogs
chmod 777 /home/wwwlogs
chown -R www:www ${Default_Website_Dir}
mkdir /usr/local/nginx/conf/vhost
if [ "${Default_Website_Dir}" != "/home/wwwroot/default" ]; then
sed -i "s#/home/wwwroot/default#${Default_Website_Dir}#g" /usr/local/nginx/conf/nginx.conf
fi
if [ "${Stack}" = "lnmp" ]; then
cat >${Default_Website_Dir}/.user.ini<<EOF
open_basedir=${Default_Website_Dir}:/tmp/:/proc/
EOF
chmod 644 ${Default_Website_Dir}/.user.ini
chattr +i ${Default_Website_Dir}/.user.ini
fi
\cp init.d/init.d.nginx /etc/init.d/nginx
chmod +x /etc/init.d/nginx
if [ "${SelectMalloc}" = "3" ]; then
mkdir /tmp/tcmalloc
chown -R www:www /tmp/tcmalloc
sed -i '/nginx.pid/a\
google_perftools_profiles /tmp/tcmalloc;' /usr/local/nginx/conf/nginx.conf
fi
}
Install_PHPMemcache()
{
echo "Install memcache php extension..."
cd ${cur_dir}/src
if echo "${Cur_PHP_Version}" | grep -Eqi '^7.';then
rm -rf pecl-memcache
git clone https://github.com/websupport-sk/pecl-memcache.git
cd pecl-memcache
else
Download_Files ${Download_Mirror}/web/memcache/${PHPMemcache_Ver}.tgz ${PHPMemcache_Ver}.tgz
Tar_Cd ${PHPMemcache_Ver}.tgz ${PHPMemcache_Ver}
fi
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config
make && make install
cd ../
}
Install_PHPMemcached()
{
echo "Install memcached php extension..."
cd ${cur_dir}/src
Get_Dist_Name
if [ "$PM" = "yum" ]; then
yum install cyrus-sasl-devel -y
Get_Dist_Version
if echo "${CentOS_Version}" | grep -Eqi '^5.'; then
yum install gcc44 gcc44-c++ libstdc++44-devel -y
export CC="gcc44"
export CXX="g++44"
fi
elif [ "$PM" = "apt" ]; then
apt-get install libsasl2-2 sasl2-bin libsasl2-2 libsasl2-dev libsasl2-modules -y
fi
Download_Files ${Download_Mirror}/web/libmemcached/${Libmemcached_Ver}.tar.gz
Tar_Cd ${Libmemcached_Ver}.tar.gz ${Libmemcached_Ver}
./configure --prefix=/usr/local/libmemcached --with-memcached
make && make install
cd ../
if echo "${Cur_PHP_Version}" | grep -Eqi '^7.';then
cd ${cur_dir}/src
rm -rf php-memcached
git clone -b php7 https://github.com/php-memcached-dev/php-memcached.git
cd php-memcached
else
Download_Files ${Download_Mirror}/web/php-memcached/${PHPMemcached_Ver}.tgz ${PHPMemcached_Ver}.tgz
Tar_Cd ${PHPMemcached_Ver}.tgz ${PHPMemcached_Ver}
fi
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config --enable-memcached --with-libmemcached-dir=/usr/local/libmemcached
make && make install
cd ../
}
Init_Install()
{
Press_Install
Print_APP_Ver
Print_Sys_Info
Check_Hosts
if [ "${DISTRO}" = "RHEL" ]; then
RHEL_Modify_Source
fi
Get_Dist_Version
if [ "${DISTRO}" = "Ubuntu" ]; then
Ubuntu_Modify_Source
fi
Set_Timezone
if [ "$PM" = "yum" ]; then
CentOS_InstallNTP
CentOS_RemoveAMP
CentOS_Dependent
elif [ "$PM" = "apt" ]; then
Deb_InstallNTP
Xen_Hwcap_Setting
Deb_RemoveAMP
Deb_Dependent
fi
Disable_Selinux
Check_Download
Install_Autoconf
Install_Libiconv
Install_Libmcrypt
Install_Mhash
Install_Mcrypt
Install_Freetype
Install_Curl
Install_Pcre
Install_Icu4c
if [ "${SelectMalloc}" = "2" ]; then
Install_Jemalloc
elif [ "${SelectMalloc}" = "3" ]; then
Install_TCMalloc
fi
if [ "$PM" = "yum" ]; then
CentOS_Lib_Opt
elif [ "$PM" = "apt" ]; then
Deb_Lib_Opt
Deb_Check_MySQL
fi
if [ "${DBSelect}" = "1" ]; then
Install_MySQL_51
elif [ "${DBSelect}" = "2" ]; then
Install_MySQL_55
elif [ "${DBSelect}" = "3" ]; then
Install_MySQL_56
elif [ "${DBSelect}" = "4" ]; then
Install_MariaDB_5
elif [ "${DBSelect}" = "5" ]; then
Install_MariaDB_10
elif [ "${DBSelect}" = "6" ]; then
Install_MySQL_57
fi
TempMycnf_Clean
}
LNMP_Stack()
{
Init_Install
if [ "${PHPSelect}" = "1" ]; then
Install_PHP_52
elif [ "${PHPSelect}" = "2" ]; then
Install_PHP_53
elif [ "${PHPSelect}" = "3" ]; then
Install_PHP_54
elif [ "${PHPSelect}" = "4" ]; then
Install_PHP_55
elif [ "${PHPSelect}" = "5" ]; then
Install_PHP_56
elif [ "${PHPSelect}" = "6" ]; then
Install_PHP_7
fi
LNMP_PHP_Opt
Install_Nginx
Creat_PHP_Tools
Add_LNMP_Startup
Check_LNMP_Install
}
LNMPA_Stack()
{
Apache_Selection
Init_Install
if [ "${ApacheSelect}" = "1" ]; then
Install_Apache_22
else
Install_Apache_24
fi
if [ "${PHPSelect}" = "1" ]; then
Install_PHP_52
elif [ "${PHPSelect}" = "2" ]; then
Install_PHP_53
elif [ "${PHPSelect}" = "3" ]; then
Install_PHP_54
elif [ "${PHPSelect}" = "4" ]; then
Install_PHP_55
elif [ "${PHPSelect}" = "5" ]; then
Install_PHP_56
elif [ "${PHPSelect}" = "6" ]; then
Install_PHP_7
fi
Install_Nginx
Creat_PHP_Tools
Add_LNMPA_Startup
Check_LNMPA_Install
}
LAMP_Stack()
{
Apache_Selection
Init_Install
if [ "${ApacheSelect}" = "1" ]; then
Install_Apache_22
else
Install_Apache_24
fi
if [ "${PHPSelect}" = "1" ]; then
Install_PHP_52
elif [ "${PHPSelect}" = "2" ]; then
Install_PHP_53
elif [ "${PHPSelect}" = "3" ]; then
Install_PHP_54
elif [ "${PHPSelect}" = "4" ]; then
Install_PHP_55
elif [ "${PHPSelect}" = "5" ]; then
Install_PHP_56
elif [ "${PHPSelect}" = "6" ]; then
Install_PHP_7
fi
Creat_PHP_Tools
Add_LAMP_Startup
Check_LAMP_Install
}
LAP_Stack()
{
Stack="lamp"
Apache_Selection
#-----Init_Install------
Press_Install
Print_APP_Ver
Print_Sys_Info
Check_Hosts
if [ "${DISTRO}" = "RHEL" ]; then
RHEL_Modify_Source
fi
Get_Dist_Version
if [ "${DISTRO}" = "Ubuntu" ]; then
Ubuntu_Modify_Source
fi
Set_Timezone
if [ "$PM" = "yum" ]; then
CentOS_InstallNTP
CentOS_RemoveAMP
CentOS_Dependent
elif [ "$PM" = "apt" ]; then
Deb_InstallNTP
Xen_Hwcap_Setting
Deb_RemoveAMP
Deb_Dependent
fi
Disable_Selinux
Check_Download
Install_Autoconf
Install_Libiconv
Install_Libmcrypt
Install_Mhash
Install_Mcrypt
Install_Freetype
Install_Curl
Install_Pcre
Install_Icu4c
if [ "${SelectMalloc}" = "2" ]; then
Install_Jemalloc
elif [ "${SelectMalloc}" = "3" ]; then
Install_TCMalloc
fi
if [ "$PM" = "yum" ]; then
CentOS_Lib_Opt
elif [ "$PM" = "apt" ]; then
Deb_Lib_Opt
Deb_Check_MySQL
fi
#-----Init_Install------
if [ "${ApacheSelect}" = "1" ]; then
Install_Apache_22
else
Install_Apache_24
fi
if [ "${PHPSelect}" = "1" ]; then
Install_PHP_52
elif [ "${PHPSelect}" = "2" ]; then
Install_PHP_53
elif [ "${PHPSelect}" = "3" ]; then
Install_PHP_54
elif [ "${PHPSelect}" = "4" ]; then
Install_PHP_55
elif [ "${PHPSelect}" = "5" ]; then
Install_PHP_56
elif [ "${PHPSelect}" = "6" ]; then
Install_PHP_7
fi
Creat_PHP_Tools
Add_LAP_Startup
Check_LAP_Install
}
LNP_Stack()
{
Stack="lnmp"
#-----Init_Install------
Press_Install
Print_APP_Ver
Print_Sys_Info
Check_Hosts
if [ "${DISTRO}" = "RHEL" ]; then
RHEL_Modify_Source
fi
Get_Dist_Version
if [ "${DISTRO}" = "Ubuntu" ]; then
Ubuntu_Modify_Source
fi
Set_Timezone
if [ "$PM" = "yum" ]; then
CentOS_InstallNTP
CentOS_RemoveAMP
CentOS_Dependent
elif [ "$PM" = "apt" ]; then
Deb_InstallNTP
Xen_Hwcap_Setting
Deb_RemoveAMP
Deb_Dependent
fi
Disable_Selinux
Check_Download
Install_Autoconf
Install_Libiconv
Install_Libmcrypt
Install_Mhash
Install_Mcrypt
Install_Freetype
Install_Curl
Install_Pcre
Install_Icu4c
if [ "${SelectMalloc}" = "2" ]; then
Install_Jemalloc
elif [ "${SelectMalloc}" = "3" ]; then
Install_TCMalloc
fi
if [ "$PM" = "yum" ]; then
CentOS_Lib_Opt
elif [ "$PM" = "apt" ]; then
Deb_Lib_Opt
Deb_Check_MySQL
fi
#-----Init_Install------
if [ "${PHPSelect}" = "1" ]; then
Install_PHP_52
elif [ "${PHPSelect}" = "2" ]; then
Install_PHP_53
elif [ "${PHPSelect}" = "3" ]; then
Install_PHP_54
elif [ "${PHPSelect}" = "4" ]; then
Install_PHP_55
elif [ "${PHPSelect}" = "5" ]; then
Install_PHP_56
elif [ "${PHPSelect}" = "6" ]; then
Install_PHP_7
fi
LNMP_PHP_Opt
Install_Nginx
Creat_PHP_Tools
Add_LNP_Startup
Check_LNP_Install
}
LN_Stack()
{
#-----Init_Install------
Press_Install
Print_APP_Ver
Print_Sys_Info
Check_Hosts
if [ "${DISTRO}" = "RHEL" ]; then
RHEL_Modify_Source
fi
Get_Dist_Version
if [ "${DISTRO}" = "Ubuntu" ]; then
Ubuntu_Modify_Source
fi
Set_Timezone
if [ "$PM" = "yum" ]; then
CentOS_InstallNTP
CentOS_RemoveAMP
CentOS_Dependent
elif [ "$PM" = "apt" ]; then
Deb_InstallNTP
Xen_Hwcap_Setting
Deb_RemoveAMP
Deb_Dependent
fi
Disable_Selinux
Check_Download
Install_Autoconf
Install_Libiconv
Install_Libmcrypt
Install_Mhash
Install_Mcrypt
Install_Freetype
Install_Curl
Install_Pcre
Install_Icu4c
if [ "${SelectMalloc}" = "2" ]; then
Install_Jemalloc
elif [ "${SelectMalloc}" = "3" ]; then
Install_TCMalloc
fi
if [ "$PM" = "yum" ]; then
CentOS_Lib_Opt
elif [ "$PM" = "apt" ]; then
Deb_Lib_Opt
Deb_Check_MySQL
fi
#-----Init_Install------
Install_Nginx_Only
Add_LN_Startup
Check_LN_Install
}
LM_Stack()
{
Init_Install
Add_LM_Startup
Check_LM_Install
}
LCP_Stack()
{
ver="1"
echo "Which memcached php extension do you choose:"
echo "Install php-memcache,(Discuz x) please enter: 1"
echo "Install php-memcached, please enter: 2"
read -p "Enter 1 or 2 (Default 1): " ver
if [ "${ver}" = "1" ]; then
echo "You choose php-memcache"
PHP_ZTS="memcache.so"
elif [ "${ver}" = "2" ]; then
echo "You choose php-memcached"
PHP_ZTS="memcached.so"
else
ver="1"
echo "You choose php-memcache"
PHP_ZTS="memcache.so"
fi
echo "====== Installing memcached ======"
Press_Install
sed -i '/memcache.so/d' /usr/local/php/etc/php.ini
sed -i '/memcached.so/d' /usr/local/php/etc/php.ini
Get_PHP_Ext_Dir
zend_ext=${zend_ext_dir}${PHP_ZTS}
if [ -s "${zend_ext}" ]; then
rm -f "${zend_ext}"
fi
if echo "${Cur_PHP_Version}" | grep -Eqi '^5.2.';then
sed -i "/extension_dir =/a\
extension = \"${PHP_ZTS}\"" /usr/local/php/etc/php.ini
elif echo "${Cur_PHP_Version}" | grep -Eqi '^5.[3456].' || echo "${Cur_PHP_Version}" | grep -Eqi '^7.';then
sed -i "/the dl()/i\
extension = \"${PHP_ZTS}\"" /usr/local/php/etc/php.ini
else
echo "Error: can't get php version!"
echo "Maybe php was didn't install or php configuration file has errors.Please check."
sleep 3
exit 1
fi
if [ "${ver}" = "1" ]; then
Install_PHPMemcache
elif [ "${ver}" = "2" ]; then
Install_PHPMemcached
fi
echo "Copy Memcached PHP Test file..."
\cp ${cur_dir}/conf/memcached${ver}.php ${Default_Website_Dir}/memcached.php
Restart_PHP
if [ -s "${zend_ext}" ]; then
echo "====== Memcached install completed ======"
echo "PHP Memcached installed successfully, enjoy it!"
else
sed -i "/${PHP_ZTS}/d" /usr/local/php/etc/php.ini
echo "PHP Memcached install failed!"
fi
}
LCS_Stack()
{
ver="1"
echo "Which memcached php extension do you choose:"
echo "Install php-memcache,(Discuz x) please enter: 1"
echo "Install php-memcached, please enter: 2"
read -p "Enter 1 or 2 (Default 1): " ver
if [ "${ver}" = "1" ]; then
echo "You choose php-memcache"
PHP_ZTS="memcache.so"
elif [ "${ver}" = "2" ]; then
echo "You choose php-memcached"
PHP_ZTS="memcached.so"
else
ver="1"
echo "You choose php-memcache"
PHP_ZTS="memcache.so"
fi
echo "====== Installing memcached ======"
Press_Install
echo "Install memcached..."
cd ${cur_dir}/src
Download_Files ${Download_Mirror}/web/memcached/${Memcached_Ver}.tar.gz ${Memcached_Ver}.tar.gz
Tar_Cd ${Memcached_Ver}.tar.gz ${Memcached_Ver}
./configure --prefix=/usr/local/memcached
make &&make install
cd ../
rm -rf ${cur_dir}/src/${Memcached_Ver}
ln -sf /usr/local/memcached/bin/memcached /usr/bin/memcached
\cp ${cur_dir}/init.d/init.d.memcached /etc/init.d/memcached
chmod +x /etc/init.d/memcached
useradd -s /sbin/nologin nobody
if [ ! -d /var/lock/subsys ]; then
mkdir -p /var/lock/subsys
fi
StartUp memcached
if [ -s /sbin/iptables ]; then
/sbin/iptables -A INPUT -p tcp --dport 11211 -j DROP
/sbin/iptables -A INPUT -p udp --dport 11211 -j DROP
if [ "$PM" = "yum" ]; then
service iptables save
elif [ "$PM" = "apt" ]; then
iptables-save > /etc/iptables.rules
fi
fi
echo "Starting Memcached..."
/etc/init.d/memcached start
if [ -s /usr/local/memcached/bin/memcached ]; then
echo "====== Memcached install completed ======"
echo "Memcached installed successfully, enjoy it!"
else
echo "Memcached install failed!"
fi
}
#------------------------- end customer methods end-------------------------------------------------
case "${Stack}" in
#nginx+php+mysql
lnmp)
Dispaly_Selection
LNMP_Stack 2>&1 | tee /root/lnmp-install.log
;;
#nginx+apache+php+mysql
lnmpa)
Dispaly_Selection
LNMPA_Stack 2>&1 | tee /root/lnmp-install.log
;;
#apache+php+mysql
lamp)
Dispaly_Selection
LAMP_Stack 2>&1 | tee /root/lnmp-install.log
;;
#apache+php
lap)
Dispaly_Selection
LAP_Stack 2>&1 | tee /root/lnmp-install.log
;;
#nginx+php
lnp)
Dispaly_Selection
LNP_Stack 2>&1 | tee /root/lnmp-install.log
;;
#nginx
ln)
Dispaly_Selection
LN_Stack 2>&1 | tee /root/lnmp-install.log
;;
#mysql
lm)
Dispaly_Selection
LM_Stack 2>&1 | tee /root/lnmp-install.log
;;
#php+memcache
lcp)
LCP_Stack 2>&1 | tee /root/lnmp-install.log
;;
#memcache server
lcs)
LCS_Stack 2>&1 | tee /root/lnmp-install.log
;;
*)
Echo_Red "Usage: $0 {lnmp|lnmpa|lamp}"
;;
esac
1
https://gitee.com/51tech/lnmp.git
git@gitee.com:51tech/lnmp.git
51tech
lnmp
lnmpx
master

搜索帮助