• nginx添加第三方模块


    1.查看nginx配置信息,

    [root@VM_0_3_centos ~]# nginx -V
    nginx version: openresty/1.15.8.2
    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 -O2' --add-module=../ngx_devel_kit-0.3.1rc1 --add-module=../echo-nginx-module-0.61 --add-module=../xss-nginx-module-0.06 --add-module=../ngx_coolkit-0.2 --add-module=../set-misc-nginx-module-0.32 --add-module=../form-input-nginx-module-0.12 --add-module=../encrypted-session-nginx-module-0.08 --add-module=../srcache-nginx-module-0.31 --add-module=../ngx_lua-0.10.15 --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.19 --add-module=../redis2-nginx-module-0.15 --add-module=../redis-nginx-module-0.3.7 --add-module=../rds-json-nginx-module-0.15 --add-module=../rds-csv-nginx-module-0.09 --add-module=../ngx_stream_lua-0.0.7 --with-ld-opt='-Wl,-rpath,/usr/local/openresty/luajit/lib -Wl,-rpath,/usr/local/openresty/luajit/lib' --with-stream --with-stream_ssl_module --with-stream_ssl_preread_module --with-http_ssl_module  --with-stream --with-stream_ssl_preread_module

    2.下载第三发模块,我安装的是nginx-http-flv-module-master 模块

    wget  https://github.com/winshining/nginx-http-flv-module/archive/master.zip

    3.进入原有的openresty目录,配置和编译。(./configure 之前的  --add-module 参数不用复制)[不用执行make install] 

    ./configure --prefix=/usr/local/openresty --with-cc-opt=-O2  --with-ld-opt=-Wl,-rpath,/usr/local/openresty/luajit/lib --with-stream --with-stream_ssl_module --with-stream_ssl_preread_module --with-http_ssl_module --add-module=/usr/local/src/download/nginx-http-flv-module-master
    make
    

    4.复制 /openresty-1.15.8.2/build/nginx-1.15.8/objs   中生成的 nginx二进制文件 到安装目录

    5.停止nginx

    6.重启

    nginx -c /usr/local/openresty/nginx/conf/nginx.conf

     

  • 相关阅读:
    算法
    UVA 10318 Security Panel(DFS剪枝 + 状压 + 思维)题解
    CodeForces 509C Sums of Digits(贪心乱搞)题解
    UVA 10382 Watering Grass(区间覆盖,贪心)题解
    CodeForces 430A Points and Segments (easy)(构造)题解
    CodeForces 459C Pashmak and Buses(构造)题解
    newcoder F石头剪刀布(DFS + 思维)题解
    newcoder H肥猪(单调队列 / 线段树)题解
    UVALive 7501 Business Cycle(二分)题解
    UVALive 7503 Change(乱搞)题解
  • 原文地址:https://www.cnblogs.com/zxqblogrecord/p/13813588.html
Copyright © 2020-2023  润新知