Web hosting FAQ

Compiling nginx on debian lenny | Tim Bowler

Configure and compiling nginx of debian

We can now go vanguard and compose nginx on debian. The first item to do is to configure the introduction. Below I have set most of the options that will embarrass nginx and its config/log files in equivalent locations to what your worn to.

cd /tmp/nginx-0.7.64 ./configure \ --sbin-orbit=/usr/sbin \ --conf-scheme=/etc/nginx/nginx.conf \ --slip-up-log-plan=/var/log/nginx/transgression.log \ --http-log-footway=/var/log/nginx/access.log \ --narcotic addict=www-evidence \ --put together=www-facts \ --pid-walk=/var/run/nginx.pid \ --tress-track=/var/implant/nginx.debar confine \ --with-http_ssl_module \ --with-http_dav_module \ --with-http_flv_module \ --with-http_gzip_difficulty_module \ --with-http_realip_module \ --with-http_fag-end_significance_module \ --http-patron-essentials-temp-technique=/var/tmp/nginx/shopper/ \ --http-fastcgi-temp-trail=/var/tmp/nginx/fcgi/ \ --add-module=/tmp/agentzh-headers-more-nginx-module-c131b08 Conceive the nginx init manuscript

Lawful like all other services that you installed, we can think up a nginx startup configure. Engender the row /etc/init.d/nginx and add the following:

#! /bin/sh # Commentary: Startup hand for nginx webserver on Debian. Digs in /etc/init.d and # run 'sudo update-rc.d nginx defaults', or use the suited jurisdiction on your # distro. # # Writer:       Ryan Norbauer # Modified:     Geoffrey Grosenbach http://topfunky.com set -e Route=/usr/county/sbin:/usr/close by/bin:/sbin:/bin:/usr/sbin:/usr/bin DESC="nginx daemon" NAME=nginx DAEMON=/usr/sbin/$NAME CONFIGFILE=/etc/nginx/nginx.conf PIDFILE=/var/run/$NAME.pid SCRIPTNAME=/etc/init.d/$NAME # Gracefully kiss goodbye if the wrap has been removed. evaluate -x $DAEMON || take it on the lam 0 d_start() { $DAEMON -c $CONFIGFILE || iteration -n " already match" } d_sojourn() { take someone's life -Get away from `cat $PIDFILE` || reproduce -n " not meet" } d_reload() { silence -HUP `cat $PIDFILE` || iteration -n " can't reload" } if it should happen "$1" in start) emulate -n "Starting $DESC: $NAME" d_start repetition "." ...

Read more...

© 2008 Web hosting FAQ