openresty安装

cd /usr/local/
mkdir data
cd data
wget http://openresty.org/download/openresty-1.9.15.1.tar.gz

cd /usr/local/data/ cd openresty-1.9.15.1/bundle/LuaJIT-2.1-20160517/ make clean make clean && make && make install cd /usr/local/data/openresty-1.9.15.1/bundle/ wget https://github.com/FRiCKLE/ngx_cache_purge/archive/2.3.tar.gz tar -zxvf 2.3 wget http://github.com/FRiCKLE/ngx_cache_purge/archive/2.3.tar.gz tar -zxvf 2.3.1 wget https://github.com/yaoweibin/nginx_upstream_check_module/archive/v0.3.0.tar.gz tar -zxvf v0.3.0 ./configure --prefix=/usr/local/openresty --with-http_realip_module --with-pcre --with-luajit --add-module=./bundle/ngx_cache_purge-2.3/ --add-module=./bundle/nginx_upstream_check_module-0.3.0/ -j2 make & make install cd /usr/local/openrestry/
./sbin/nginx

配置参数:

--with***                安装一些内置/集成的模块

--with-http_realip_module  取用户真实ip模块

-with-pcre                Perl兼容的达式模块

--with-luajit              集成luajit模块

 

--add-module           添加自定义的第三方模块,如此次的ngx_che_purge

--prefix       指定安装路径

安装模块说明:

openresty-1.9.15.1/bundle目录里存放着nginx核心和很多第三方模块,比如有我们需要的Lua和LuaJIT。

安装LuaJIT

下载ngx_cache_purge模块,该模块用于清理nginx缓存

下载nginx_upstream_check_module模块,该模块用于ustream健康检查

转载于:https://www.cnblogs.com/sagech/p/5612056.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值