nginx: upgrade to 1.6.0, expose many more modules

By default, we now build all the optional nginx modules, including the
out-of-band ones like moreheaders and rtmp support.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
This commit is contained in:
Austin Seipp 2014-05-02 01:18:44 -05:00
parent 368a677c97
commit b10f4af8f9
2 changed files with 37 additions and 20 deletions

View file

@ -1,38 +1,39 @@
{ stdenv, fetchurl, fetchgit, openssl, zlib, pcre, libxml2, libxslt, expat
, gd, geoip
, rtmp ? false
, fullWebDAV ? false
, syslog ? false
, moreheaders ? false}:
let
version = "1.4.7";
version = "1.6.0";
mainSrc = fetchurl {
url = "http://nginx.org/download/nginx-${version}.tar.gz";
sha256 = "09mnw4f1yk64f21xq4k65x4r76pmrszyzc4iixkr0w41fr5gzf13";
sha256 = "06pwmg4qyd1sirpyl47s6qp94qc8a36dlkaw5pgv7s63l5bxffll";
};
rtmp-ext = fetchgit {
url = git://github.com/arut/nginx-rtmp-module.git;
rev = "1cfb7aeb582789f3b15a03da5b662d1811e2a3f1";
sha256 = "03ikfd2l8mzsjwx896l07rdrw5jn7jjfdiyl572yb9jfrnk48fwi";
url = https://github.com/arut/nginx-rtmp-module.git;
rev = "8c2229cce5d4d4574e8fb7b130281497f746f0fa";
sha256 = "6caea2a13161345c3fc963679730be54cebebddf1406ac7d4ef4ce72ac0b90b0";
};
dav-ext = fetchgit {
url = git://github.com/arut/nginx-dav-ext-module.git;
rev = "54cebc1f21fc13391aae692c6cce672fa7986f9d";
sha256 = "1dvpq1fg5rslnl05z8jc39sgnvh3akam9qxfl033akpczq1bh8nq";
url = "https://github.com/arut/nginx-dav-ext-module";
rev = "89d582d31ab624ff1c6a4cec0c1a52839507b323";
sha256 = "2175f83a291347504770d2a4bb5069999e9f7408697bd49464b6b54e994493e1";
};
syslog-ext = fetchgit {
url = https://github.com/yaoweibin/nginx_syslog_patch.git;
rev = "165affd9741f0e30c4c8225da5e487d33832aca3";
sha256 = "14dkkafjnbapp6jnvrjg9ip46j00cr8pqc2g7374z9aj7hrvdvhs";
rev = "690a054a0e440323bba58ed3be12d705d3fb9cf2";
sha256 = "0678bc2960dfa31adfc2997c079947c32dde28d6785ee423fa7f5badbb925fbe";
};
moreheaders-ext = fetchgit {
url = https://github.com/agentzh/headers-more-nginx-module.git;
rev = "refs/tags/v0.23";
sha256 = "12pbjgsxnvcf2ff2i2qdn39q4cm5czlgrng96j8ml4cgxvnbdh39";
url = https://github.com/openresty/headers-more-nginx-module.git;
rev = "0c6e05d3125a97892a250e9ba8b7674163ba500b";
sha256 = "e121d97fd3c81c64e6cbf6902bbcbdb01be9ac985c6832d40434379d5e998eaf";
};
in
@ -40,19 +41,30 @@ stdenv.mkDerivation rec {
name = "nginx-${version}";
src = mainSrc;
buildInputs = [ openssl zlib pcre libxml2 libxslt
buildInputs =
[ openssl zlib pcre libxml2 libxslt gd geoip
] ++ stdenv.lib.optional fullWebDAV expat;
patches = if syslog then [ "${syslog-ext}/syslog_1.4.0.patch" ] else [];
patches = if syslog then [ "${syslog-ext}/syslog_1.5.6.patch" ] else [];
configureFlags = [
"--with-http_ssl_module"
"--with-http_spdy_module"
"--with-http_realip_module"
"--with-http_addition_module"
"--with-http_xslt_module"
"--with-http_image_filter_module"
"--with-http_geoip_module"
"--with-http_sub_module"
"--with-http_dav_module"
"--with-http_flv_module"
"--with-http_mp4_module"
"--with-http_gunzip_module"
"--with-http_gzip_static_module"
"--with-http_auth_request_module"
"--with-http_random_index_module"
"--with-http_secure_link_module"
"--with-http_degradation_module"
"--with-http_stub_status_module"
"--with-ipv6"
# Install destination problems
@ -72,9 +84,9 @@ stdenv.mkDerivation rec {
meta = {
description = "A reverse proxy and lightweight webserver";
homepage = http://nginx.org;
maintainers = [ stdenv.lib.maintainers.raskin ];
platforms = stdenv.lib.platforms.all;
inherit version;
homepage = http://nginx.org;
license = stdenv.lib.licenses.bsd2;
platforms = stdenv.lib.platforms.all;
maintainers = with stdenv.lib.maintainers; [ thoughtpolice raskin ];
};
}

View file

@ -6552,7 +6552,12 @@ let
myserver = callPackage ../servers/http/myserver { };
nginx = callPackage ../servers/http/nginx { };
nginx = callPackage ../servers/http/nginx {
rtmp = true;
fullWebDAV = true;
syslog = true;
moreheaders = true;
};
ngircd = callPackage ../servers/irc/ngircd { };