首页 > web > nginx

tengine添加云锁防护模块
时间:2016-08-17 15:07:32  点击: 来源:  作者:

说明,本文适用于之前已安装过tengine但没有安装云锁模块的.
环境:centos,云锁,tengine
yum -y install jemalloc pcre* openssl*安装前做好备份: cp /usr/local/nginx/sbin/nginx /usr/local/nginx/sbin/nginx ...

说明,本文适用于之前已安装过tengine但没有安装云锁模块的.
环境:centos,云锁,tengine

yum -y install jemalloc pcre* openssl*

安装前做好备份:

cp /usr/local/nginx/sbin/nginx   /usr/local/nginx/sbin/nginx.bak


1.下载(需要重新下载之前的tengine版本):
下载tengine:

#cd /usr/local/
#wget http://tengine.taobao.org/download/tengine-2.1.2.tar.gz
#tar zxvf tengine-2.1.2.tar.gz


下载云锁模块:

#wget https://codeload.github.com/yunsuo-open/nginx-plugin/zip/master -O nginx-plugin-master.zip
#unzip nginx-plugin-master.zip



2.查看之前都加载了什么模块:

#nginx -V




我本机加载模块大致如下:

--with-http_ssl_module --with-http_flv_module --with-http_stub_status_module --with-http_gzip_static_module --with-http_upstream_check_module


3.安装与配置(常用模块):

#cd tengine-2.1.2
#./configure --prefix=/usr/local/nginx --with-http_ssl_module --with-http_flv_module --with-http_stub_status_module --with-http_gzip_static_module --with-http_upstream_check_module  --add-module=/usr/local/nginx-plugin-master




即,在正常安装tengine的步骤下多出: --add-module=/usr/local/nginx-plugin-master

# make


注意:切记不要执行make install ,不然会覆盖掉之前配置的 nginx.conf

rm -rf /usr/local/nginx/sbin/nginx
cp objs/nginx /usr/local/nginx/sbin/nginx
service nginx restart


4.让云锁识别您自己编译的tengine:

cd /usr/local/yunsuo_agent/nginx/
./configure_compile_nginx   /usr/local/nginx

”您可通过以下微信二维码,赞赏作者“
 
 
发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表
推荐资讯
linux服务器同步互联网时间
linux服务器同步互联
亚马逊云lightsail服务器使用教程 | 亚马逊云lightsail使用指南
亚马逊云lightsail服
hostdare 4折优惠,直接降价60% 美国洛杉矶低至 $10.4/年 768M内存/1核/10gNVMe/500g流量
hostdare 4折优惠,直接
六类网线cat6a和cat6e的区别
六类网线cat6a和cat6e
相关文章
栏目更新
栏目热门

关于我们 | 广告服务 | 联系我们 | 网站地图 | 免责声明 | WAP | RSS


Copyright © 运维之家 2013-2023