diff -Nru nginx-0.8.53/debian/changelog nginx-0.8.53/debian/changelog --- nginx-0.8.53/debian/changelog 2010-11-29 07:48:50.000000000 +0100 +++ nginx-0.8.53/debian/changelog 2010-12-19 02:44:27.000000000 +0100 @@ -1,3 +1,34 @@ +nginx (0.8.53-2ubuntu1) natty; urgency=low + + * Merge from debian unstable (LP: #692083, #673366). Remaining changes: + - debian/patches/nginx-html5-codecs.diff: Add support for html5 codecs. + + -- Angel Abad Sun, 19 Dec 2010 02:18:36 +0100 + +nginx (0.8.53-2) unstable; urgency=low + + [Kartik Mistry] + * debian/conf/mime.types: + + Added html5 codecs support (Closes: #605212) + * debian/conf/fastcgi_params: + + Fixed typo (Closes: #605582) + + [Michael Lustfield] + * debian/conf/nginx.conf: + + Reduced worker_connections to 768 (Closes: #605529) + * Add an nginx site management script to nginx-doc. (Closes: #593580) + + debian/help/examples/nginx_modsite: Added. + * debian/nginx.logrotate: + + Added prerotate chunk for awstats. (Closes: #590098) + * debian/copyright: + + Added Michael Lustfield + * Created nginx-doc: + + Added 'Package: nginx-doc' section to debian/control + + Moved debian/nginx.examples -> debian/nginx-doc.examples + + Moved debian/nginx.docs -> debian/nginx-doc.docs + + -- Kartik Mistry Mon, 06 Dec 2010 11:26:22 +0530 + nginx (0.8.53-1ubuntu2) natty; urgency=low * Drop all Ubuntu changes that have landed in Debian in 0.8.53-1, diff -Nru nginx-0.8.53/debian/conf/fastcgi_params nginx-0.8.53/debian/conf/fastcgi_params --- nginx-0.8.53/debian/conf/fastcgi_params 2010-11-26 14:23:27.000000000 +0100 +++ nginx-0.8.53/debian/conf/fastcgi_params 2010-12-17 01:03:12.000000000 +0100 @@ -4,7 +4,7 @@ fastcgi_param CONTENT_LENGTH $content_length; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; -fastcgi_param SCRIPT_NAM $fastcgi_script_name; +fastcgi_param SCRIPT_NAME $fastcgi_script_name; fastcgi_param REQUEST_URI $request_uri; fastcgi_param DOCUMENT_URI $document_uri; fastcgi_param DOCUMENT_ROOT $document_root; diff -Nru nginx-0.8.53/debian/conf/mime.types nginx-0.8.53/debian/conf/mime.types --- nginx-0.8.53/debian/conf/mime.types 2010-11-26 14:23:27.000000000 +0100 +++ nginx-0.8.53/debian/conf/mime.types 2010-12-17 01:03:12.000000000 +0100 @@ -56,11 +56,13 @@ application/octet-stream eot; application/octet-stream iso img; application/octet-stream msi msp msm; + application/ogg ogx; audio/midi mid midi kar; audio/mpeg mpga mpega mp2 mp3 m4a; audio/ogg oga ogg spx; audio/x-realaudio ra; + audio/webm weba; video/3gpp 3gpp 3gp; video/mp4 mp4; diff -Nru nginx-0.8.53/debian/conf/nginx.conf nginx-0.8.53/debian/conf/nginx.conf --- nginx-0.8.53/debian/conf/nginx.conf 2010-11-26 14:23:27.000000000 +0100 +++ nginx-0.8.53/debian/conf/nginx.conf 2010-12-17 01:03:12.000000000 +0100 @@ -3,8 +3,8 @@ pid /var/run/nginx.pid; events { - worker_connections 1024; - # multi_accept on; + worker_connections 768; + # multi_accept on; } http { diff -Nru nginx-0.8.53/debian/control nginx-0.8.53/debian/control --- nginx-0.8.53/debian/control 2010-11-29 07:46:12.000000000 +0100 +++ nginx-0.8.53/debian/control 2010-12-17 01:03:12.000000000 +0100 @@ -22,7 +22,7 @@ Package: nginx Architecture: any Depends: ${misc:Depends}, ${shlibs:Depends}, lsb-base (>= 3.2-14) -Suggests: ufw +Suggests: ufw, nginx-doc Provides: httpd Description: small, but very powerful and efficient web server and mail proxy Nginx (engine x) is a web server created by Igor Sysoev and kindly provided to @@ -45,3 +45,15 @@ . This package provides debugging symbols for nginx, to assist in debugging issues that you may find. It should not be required for normal operation. + +Package: nginx-doc +Architecture: any +Section: doc +Depends: ${misc:Depends} +Description: Documentation for nginx + Nginx (engine x) is a web server created by Igor Sysoev and kindly provided to + the open-source community. This server can be used as standalone HTTP server + and as a reverse proxy server before some Apache or another big server to + reduce load to backend servers by many concurrent HTTP-sessions. + . + This package provides extra documentation for Nginx. diff -Nru nginx-0.8.53/debian/copyright nginx-0.8.53/debian/copyright --- nginx-0.8.53/debian/copyright 2010-07-17 08:18:32.000000000 +0200 +++ nginx-0.8.53/debian/copyright 2010-12-17 01:03:12.000000000 +0100 @@ -37,4 +37,5 @@ Copyright: © 2006-2010, Jose Parrella , Fabio Tranchitella © 2009-2010, Kartik Mistry + © 2010, Michael Lustfield License: Same as upstream license. diff -Nru nginx-0.8.53/debian/help/examples/nginx_modsite nginx-0.8.53/debian/help/examples/nginx_modsite --- nginx-0.8.53/debian/help/examples/nginx_modsite 1970-01-01 01:00:00.000000000 +0100 +++ nginx-0.8.53/debian/help/examples/nginx_modsite 2010-12-05 13:20:25.000000000 +0100 @@ -0,0 +1,162 @@ +#!/bin/bash + +## +# File: +# nginx_modsite +# Description: +# Provides a basic script to automate enabling and disabling websites found +# in the default configuration directories: +# /etc/nginx/sites-available and /etc/nginx/sites-enabled +# For easy access to this script, copy it into the directory: +# /usr/local/sbin +# Run this script without any arguments or with -h or --help to see a basic +# help dialog displaying all options. +## + +# Copyright (C) 2010 Michael Lustfield + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. + +## +# Default Settings +## + +NGINX_CONF_FILE="$(awk -F= -v RS=' ' '/conf-path/ {print $2}' <<< $(nginx -V 2>&1))" +NGINX_CONF_DIR="${NGINX_CONF_FILE%/*}" +NGINX_SITES_AVAILABLE="$NGINX_CONF_DIR/sites-available" +NGINX_SITES_ENABLED="$NGINX_CONF_DIR/sites-enabled" +SELECTED_SITE="$2" + +## +# Script Functions +## + +ngx_enable_site() { + [[ ! "$SELECTED_SITE" ]] && + ngx_select_site "not_enabled" + + [[ ! -e "$NGINX_SITES_AVAILABLE/$SELECTED_SITE" ]] && + ngx_error "Site does not appear to exist." + [[ -e "$NGINX_SITES_ENABLED/$SELECTED_SITE" ]] && + ngx_error "Site appears to already be enabled" + + ln -sf "$NGINX_SITES_AVAILABLE/$SELECTED_SITE" -T "$NGINX_SITES_ENABLED/$SELECTED_SITE" + ngx_reload +} + +ngx_disable_site() { + [[ ! "$SELECTED_SITE" ]] && + ngx_select_site "is_enabled" + + [[ ! -e "$NGINX_SITES_AVAILABLE/$SELECTED_SITE" ]] && + ngx_error "Site does not appear to be \'available\'. - Not Removing" + [[ ! -e "$NGINX_SITES_ENABLED/$SELECTED_SITE" ]] && + ngx_error "Site does not appear to be enabled." + + rm -f "$NGINX_SITES_ENABLED/$SELECTED_SITE" + ngx_reload +} + +ngx_list_site() { + echo "Available sites:" + ngx_sites "available" + echo "Enabled Sites" + ngx_sites "enabled" +} + +## +# Helper Functions +## + +ngx_select_site() { + sites_avail=($NGINX_SITES_AVAILABLE/*) + sa="${sites_avail[@]##*/}" + sites_en=($NGINX_SITES_ENABLED/*) + se="${sites_en[@]##*/}" + + case "$1" in + not_enabled) sites=$(comm -13 <(printf "%s\n" $se) <(printf "%s\n" $sa));; + is_enabled) sites=$(comm -12 <(printf "%s\n" $se) <(printf "%s\n" $sa));; + esac + + ngx_prompt "$sites" +} + +ngx_prompt() { + sites=($1) + i=0 + + echo "SELECT A WEBSITE:" + for site in ${sites[@]}; do + echo -e "$i:\t${sites[$i]}" + ((i++)) + done + + read -p "Enter number for website: " i + SELECTED_SITE="${sites[$i]}" +} + +ngx_sites() { + case "$1" in + available) dir="$NGINX_SITES_AVAILABLE";; + enabled) dir="$NGINX_SITES_ENABLED";; + esac + + for file in $dir/*; do + echo -e "\t${file#*$dir/}" + done +} + +ngx_reload() { + read -p "Would you like to reload the Nginx configuration now? (Y/n) " reload + [[ "$reload" != "n" && "$reload" != "N" ]] && invoke-rc.d nginx reload +} + +ngx_error() { + echo -e "${0##*/}: ERROR: $1" + [[ "$2" ]] && ngx_help + exit 1 +} + +ngx_help() { + echo "Usage: ${0##*/} [options]" + echo "Options:" + echo -e "\t<-e|--enable> \tEnable site" + echo -e "\t<-d|--disable> \tDisable site" + echo -e "\t<-l|--list>\t\tList sites" + echo -e "\t<-h|--help>\t\tDisplay help" + echo -e "\n\tIf is left out a selection of options will be presented." + echo -e "\tIt is assumed you are using the default sites-enabled and" + echo -e "\tsites-disabled located at $NGINX_CONF_DIR." +} + +## +# Core Piece +## + +case "$1" in + -e|--enable) ngx_enable_site;; + -d|--disable) ngx_disable_site;; + -l|--list) ngx_list_site;; + -h|--help) ngx_help;; + *) ngx_error "No Options Selected" 1; ngx_help;; +esac diff -Nru nginx-0.8.53/debian/nginx-doc.docs nginx-0.8.53/debian/nginx-doc.docs --- nginx-0.8.53/debian/nginx-doc.docs 1970-01-01 01:00:00.000000000 +0100 +++ nginx-0.8.53/debian/nginx-doc.docs 2010-12-03 06:51:13.000000000 +0100 @@ -0,0 +1,3 @@ +README +debian/NEWS.Debian +debian/help/docs/* diff -Nru nginx-0.8.53/debian/nginx-doc.examples nginx-0.8.53/debian/nginx-doc.examples --- nginx-0.8.53/debian/nginx-doc.examples 1970-01-01 01:00:00.000000000 +0100 +++ nginx-0.8.53/debian/nginx-doc.examples 2010-12-03 06:51:13.000000000 +0100 @@ -0,0 +1 @@ +debian/help/examples/* diff -Nru nginx-0.8.53/debian/nginx.docs nginx-0.8.53/debian/nginx.docs --- nginx-0.8.53/debian/nginx.docs 2010-11-26 14:13:21.000000000 +0100 +++ nginx-0.8.53/debian/nginx.docs 1970-01-01 01:00:00.000000000 +0100 @@ -1,3 +0,0 @@ -README -debian/NEWS.Debian -debian/help/docs/* diff -Nru nginx-0.8.53/debian/nginx.examples nginx-0.8.53/debian/nginx.examples --- nginx-0.8.53/debian/nginx.examples 2010-11-26 14:18:01.000000000 +0100 +++ nginx-0.8.53/debian/nginx.examples 1970-01-01 01:00:00.000000000 +0100 @@ -1 +0,0 @@ -debian/help/examples/* diff -Nru nginx-0.8.53/debian/nginx.logrotate nginx-0.8.53/debian/nginx.logrotate --- nginx-0.8.53/debian/nginx.logrotate 2009-11-26 17:44:46.000000000 +0100 +++ nginx-0.8.53/debian/nginx.logrotate 2010-12-17 01:03:12.000000000 +0100 @@ -7,6 +7,11 @@ notifempty create 640 root adm sharedscripts + prerotate + if [ -d /etc/logrotate.d/httpd-prerotate ]; then \ + run-parts /etc/logrotate.d/httpd-prerotate; \ + fi; \ + endscript postrotate [ ! -f /var/run/nginx.pid ] || kill -USR1 `cat /var/run/nginx.pid` endscript