Recompile NGINX with "--with-http_stub_status_module" configure line
Solution 1:
Download the source from nginx.org and unpack it.
Use/path/to/your/nginx/binary -V
to get your current configure line.
Modify it as you see fit, and run the configure file from the nginx source with your new configure line. Then run make, make install and make upgrade and you're all updated.
Solution 2:
I agree with "Martin F" -- he described the simplest and proven way to upgrade Nginx from the official sources.
However, some people would like to go "Debian way" of installing source packages. In this case, the scenario is as follows:
- You must have
dpkg-dev
,dpatch
,devscripts
installed - Go to the directory where you build packages, e.g.
/usr/src
. Download Nginx package sources:apt-get source nginx=1.0.4
- Directory
nginx-1.0.4
contains Nginx sources along with Debian package configuration, installation script, etc. If you just want to add another option to Nginx configuration command line, editdebian/rules
file. Note that Nginx package comes in three flavors:extra
,full
and I don't remember the third. Choose whatever you like and modify its configuration. - Update the ChangeLog:
dch --local your-user-id 'Added perl module; Removed ipv6, mail, xslt modules'
- Build the package:
debuild -us -uc -b
After this, you should have Debian packages (e.g. nginx-full_1.0.4-1your-user-id1_amd64.deb
) in /usr/src
. Just install the package of your choice with dpkg -i <file>