首先要安装编译环境

yum group install "Development Tools"
 yum install pcre-devel openssl-devel gcc curl postgresql-devel geoip-devel

  

SRE实战 互联网时代守护先锋,助力企业售后服务体系运筹帷幄!一键直达领取阿里云限量特价优惠。

从下载页 Download下载最新的 OpenResty® 源码包,将其解压:

tar -xzvf openresty-VERSION.tar.gz

 

然后

./configure --prefix=/opt/openresty \
            --with-luajit \
            --without-http_redis2_module \
            --with-http_iconv_module \
            --with-http_postgres_module  \
            --with-stream  \
            --with-stream=dynamic     \
            --with-stream_ssl_module        \
            --with-stream_realip_module     \
            --with-stream_geoip_module    \
            --with-stream_geoip_module=dynamic  \
            --with-stream_ssl_preread_module 

 

 然后

gmake
gmake install

  

扫码关注我们
微信号:SRE实战
拒绝背锅 运筹帷幄