nginx增加新模块
以gzip这个模块为例,讲述一下,在nginx中如何安装新的模块
1、首先查看nginx已经安装了哪些模块。
nginx –V
2、发现没有gzip模块,安装
进入nginx的安装目录中,不是nginx的软件目录。
在已有模块种写上要安装的模块,执行下边的命令
./configure \
--prefix=/usr/local/ywgh/nginx \
--http-client-body-temp-path=/tmp/clientbody \
--http-proxy-temp-path=/tmp/proxy \
--http-fastcgi-temp-path=/tmp/fastcgi \
--http-uwsgi-temp-path=/tmp/uwsgi \
--http-scgi-temp-path=/tmp/scgi \
--user=www \
--group=www \
--with-file-aio \
--with-http_realip_module \
--with-http_ssl_module \
--with-openssl=/usr/local/src/software/nginx/openssl \
--with-http_gunzip_module \
--with-http_gzip_static_module \
--with-zlib=/usr/local/src/software/nginx/zlib \
--with-http_stub_status_module \
--with-pcre=/usr/local/src/software/nginx/pcre \
3、然后编译,覆盖
直接make就行,不需要再make install了,如果要重新安装就使用make install,就直接覆盖了。
然后新产生的可执行文件nginx在安装目录中的objs目录下。
将objs目录下的nginx 复制到软件位置的nginx中。进行覆盖就可以了。覆盖的时候,需要先关闭nginx
- centos中安装nginx与新增加https模块支持
- 为nginx增加nginx_http_concat模块
- nginx 编译增加新的模块
- apt-get 方式安装nginx后,增加模块--with-http_perl_module
- 记录给nginx增加模块过程中碰到的问题
- nginx下增加模块
- 在已经安装Nginx的基础上增加新Nginx-echo模块
- 在已经安装的nginx上,增加ssl模块
- nginx无痛升级并增加nginx-gridfs模块支持
- nginx模块开发-增加nginx内置变量
- Nginx增加模块
- Nginx平滑升级,并增加清除缓存模块
- Nginx增加模块
- nginx 修改flv模块,增加end 参数
- 在已经安装的nginx上,增加ssl模块
- centos6.5生产环境编译安装nginx-1.11.3并增加第三方模块ngx_cache_purge、nginx_upstream_check、ngx_devel_kit、lua-nginx
- nginx增加编译模块
- centos6.5生产环境编译安装nginx-1.11.3并增加第三方模块ngx_cache_purge、nginx_upstream_check、ngx_devel_kit、lua-nginx
- 在已经安装好的Nginx上增加新模块
- NGINX 加载动态模块(NGINX 1.9.11开始增加加载动态模块支持)