zoukankan      html  css  js  c++  java
  • OpenResty源码编译安装

      本篇将介绍如何在CentOS7上源代码编译安装OpenResty 1.13.6.1。

    Preface 安装依赖

    # yum install epel-release -y
    # yum group install "Development Tools" -y    # 安装基本编译工具
    # yum install gcc pcre pcre-devel zlib zlib-devel openssl openssl-devel -y

    下载源代码

    # cd /opt
    # wget https://openresty.org/download/openresty-1.13.6.1.tar.gz                        # 下载openresty
    # tar -xvf openresty-1.13.6.1.tar.gz

    编译

    # cd openresty-1.13.6.1/
    # ./configure
    # make && make install

    使用

       如下:

    # /usr/local/openresty/bin/openresty -v
    nginx version: openresty/1.13.6.1
    # /usr/local/openresty/bin/openresty -V
    nginx version: openresty/1.13.6.1
    built by gcc 4.8.5 20150623 (Red Hat 4.8.5-39) (GCC) 
    built with OpenSSL 1.0.2k-fips  26 Jan 2017
    TLS SNI support enabled
    configure arguments: --prefix=/usr/local/openresty/nginx --with-cc-opt=-O2 --add-module=../ngx_devel_kit-0.3.0 --add-module=../echo-nginx-module-0.61 --add-module=../xss-nginx-module-0.05 --add-module=../ngx_coolkit-0.2rc3 --add-module=../set-misc-nginx-module-0.31 --add-module=../form-input-nginx-module-0.12 --add-module=../encrypted-session-nginx-module-0.07 --add-module=../srcache-nginx-module-0.31 --add-module=../ngx_lua-0.10.11 --add-module=../ngx_lua_upstream-0.07 --add-module=../headers-more-nginx-module-0.33 --add-module=../array-var-nginx-module-0.05 --add-module=../memc-nginx-module-0.18 --add-module=../redis2-nginx-module-0.14 --add-module=../redis-nginx-module-0.3.7 --add-module=../rds-json-nginx-module-0.15 --add-module=../rds-csv-nginx-module-0.08 --add-module=../ngx_stream_lua-0.0.3 --with-ld-opt=-Wl,-rpath,/usr/local/openresty/luajit/lib --with-stream --with-stream_ssl_module --with-http_ssl_module
  • 相关阅读:
    Service Fabric 用 Powershell 部署应用到本地
    Redis 高可用之哨兵模式(二)
    Redis 高可用之哨兵模式
    微服务之Service Fabric 系列 (一):概览、环境安装
    Nginx 负载均衡
    Redis 总结
    微服务示例-Spring Cloud
    ASP.NET Core Linux 发布
    Windows RabbitMQ 安装
    Nancy 框架学习
  • 原文地址:https://www.cnblogs.com/Hi-blog/p/How-To-Compile-OpenResty-From-Source-Code.html
Copyright © 2011-2022 走看看