nginx adding new modules

To gzip this module, for example, talk about how to install the new module in nginx
1, first check which modules have been installed nginx.
-V nginx
nginx adding new modules
2, found no gzip module, installed
into the nginx installation directory, software directory is not the nginx.
Module on the existing species write module to be installed, execute the following command
./configure \
--prefix = / usr / local / ywgh / nginx \
--http-clientbody-the TEMP-path = / tmp / clientbody \
Proxy-TEMP----http path = / tmp / Proxy \
--http-FastCGI-TEMP-path = / tmp / FastCGI \
--http-path-to uwsgi-TEMP = / tmp / to uwsgi \
--http-SCGI = path--temp / tmp / SCGI \
--user = WWW \
--group = WWW \
--with-AIO-File \
--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, then compiled, covering
directly make on the line, do not need to make install, if you want to re-install it using make install, directly covered.
nginx adding new modules
Then the newly generated executable file in the installation directory nginx under objs directory.
Copy nginx under objs directory to the location of the nginx in software. Covering it. When covered, we need to close the nginx

Source
operation and maintenance Guild: nginx adding new modules

Guess you like

Origin blog.51cto.com/4856198/2442187