mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-22 05:19:00 +02:00
cc1d82196c
The patches previously applied have been included upstream. Upstream changelog (only MAJOR/MEDIUM): 2018/07/30 : 1.8.13 - BUG/MEDIUM: h2: don't accept new streams if conn_streams are still in excess - BUG/MEDIUM: h2: never leave pending data in the output buffer on close - BUG/MEDIUM: h2: make sure the last stream closes the connection after a timeout - BUG/MEDIUM: threads: Fix the exit condition of the thread barrier - BUG/MEDIUM: stream-int: don't immediately enable reading when the buffer was reportedly full - BUG/MEDIUM: stats: don't ask for more data as long as we're responding - BUG/MEDIUM: threads/sync: use sched_yield when available - BUG/MEDIUM: h2: prevent orphaned streams from blocking a connection forever - BUG/MEDIUM: threads: properly fix nbthreads == MAX_THREADS - BUG/MEDIUM: threads: unbreak "bind" referencing an incorrect thread number - MEDIUM: proxy_protocol: Convert IPs to v6 when protocols are mixed 2018/06/27 : 1.8.12 - BUG/MAJOR: stick_table: Complete incomplete SEGV fix 2018/06/26 : 1.8.11 - BUG/MAJOR: Stick-tables crash with segfault when the key is not in the stick-table 2018/06/22 : 1.8.10 - BUG/MEDIUM: spoe: Flags are not encoded in network order - BUG/MEDIUM: contrib/mod_defender: Use network order to encode/decode flags - BUG/MEDIUM: contrib/modsecurity: Use network order to encode/decode flags - BUG/MEDIUM: cache: don't cache when an Authorization header is present - BUG/MEDIUM: dns: Delay the attempt to run a DNS resolution on check failure. - BUG/MEDIUM: fd: Only check update_mask against all_threads_mask. - BUG/MEDIUM: servers: Add srv_addr default placeholder to the state file - BUG/MEDIUM: lua/socket: Length required read doesn't work - BUG/MEDIUM: stick-tables: Decrement ref_cnt in table_* converters - BUG/MEDIUM: spoe: Return an error when the wrong ACK is received in sync mode - BUG/MEDIUM: lua/socket: wrong scheduling for sockets - BUG/MAJOR: lua: Dead lock with sockets - BUG/MEDIUM: lua/socket: Notification error - BUG/MEDIUM: lua/socket: Sheduling error on write: may dead-lock - BUG/MEDIUM: lua/socket: Buffer error, may segfault - MAJOR: spoe: upgrade the SPOP version to 2.0 and remove the support for 1.0 - BUG/MEDIUM: threads: handle signal queue only in thread 0 - BUG/MAJOR: map: fix a segfault when using http-request set-map - BUG/MAJOR: ssl: Random crash with cipherlist capture - BUG/MAJOR: ssl: OpenSSL context is stored in non-reserved memory slot - BUG/MEDIUM: fd: Don't modify the update_mask in fd_dodelete(). - BUG/MEDIUM: threads: Use the sync point to check active jobs and exit
60 lines
1.8 KiB
Nix
60 lines
1.8 KiB
Nix
{ useLua ? !stdenv.isDarwin
|
|
, usePcre ? true
|
|
, stdenv, fetchurl
|
|
, openssl, zlib, lua5_3 ? null, pcre ? null
|
|
}:
|
|
|
|
assert useLua -> lua5_3 != null;
|
|
assert usePcre -> pcre != null;
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "haproxy";
|
|
version = "1.8.13";
|
|
name = "${pname}-${version}";
|
|
|
|
src = fetchurl {
|
|
url = "https://www.haproxy.org/download/${stdenv.lib.versions.majorMinor version}/src/${name}.tar.gz";
|
|
sha256 = "2bf5dafbb5f1530c0e67ab63666565de948591f8e0ee2a1d3c84c45e738220f1";
|
|
};
|
|
|
|
buildInputs = [ openssl zlib ]
|
|
++ stdenv.lib.optional useLua lua5_3
|
|
++ stdenv.lib.optional usePcre pcre;
|
|
|
|
# TODO: make it work on bsd as well
|
|
makeFlags = [
|
|
"PREFIX=\${out}"
|
|
("TARGET=" + (if stdenv.isSunOS then "solaris"
|
|
else if stdenv.isLinux then "linux2628"
|
|
else if stdenv.isDarwin then "osx"
|
|
else "generic"))
|
|
];
|
|
buildFlags = [
|
|
"USE_OPENSSL=yes"
|
|
"USE_ZLIB=yes"
|
|
] ++ stdenv.lib.optionals usePcre [
|
|
"USE_PCRE=yes"
|
|
"USE_PCRE_JIT=yes"
|
|
] ++ stdenv.lib.optionals useLua [
|
|
"USE_LUA=yes"
|
|
"LUA_LIB=${lua5_3}/lib"
|
|
"LUA_INC=${lua5_3}/include"
|
|
] ++ stdenv.lib.optional stdenv.isDarwin "CC=cc";
|
|
|
|
meta = {
|
|
description = "Reliable, high performance TCP/HTTP load balancer";
|
|
longDescription = ''
|
|
HAProxy is a free, very fast and reliable solution offering high
|
|
availability, load balancing, and proxying for TCP and HTTP-based
|
|
applications. It is particularly suited for web sites crawling under very
|
|
high loads while needing persistence or Layer7 processing. Supporting
|
|
tens of thousands of connections is clearly realistic with todays
|
|
hardware.
|
|
'';
|
|
homepage = http://haproxy.1wt.eu;
|
|
maintainers = with stdenv.lib.maintainers; [ fuzzy-id garbas ];
|
|
platforms = with stdenv.lib.platforms; linux ++ darwin;
|
|
license = stdenv.lib.licenses.gpl2;
|
|
};
|
|
}
|