From 08f44723363d101b6059c947d0b52582e5d79d88 Mon Sep 17 00:00:00 2001 From: Clark Boylan Date: Thu, 22 Aug 2013 14:59:15 -0700 Subject: [PATCH] Use the haproxy source balance method. * modules/cgit/manifests/init.pp: HTTP(S) access to the git cluster may end up making connections to different node members potentially causing fetches to fail when a ref is visible on one node but not on another. Fix this by using the source balance method. Every request from a single host will be served by one backend node unless nodes are added or removed. Change-Id: Iedca1938277020b837eb1607e43013f5feb2ed2d --- modules/cgit/manifests/init.pp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/modules/cgit/manifests/init.pp b/modules/cgit/manifests/init.pp index 1937db33c8..71656d1135 100644 --- a/modules/cgit/manifests/init.pp +++ b/modules/cgit/manifests/init.pp @@ -238,7 +238,8 @@ class cgit( mode => 'tcp', collect_exported => false, options => { - 'option' => [ + 'balance' => 'source', + 'option' => [ 'tcplog', ], }, @@ -249,6 +250,7 @@ class cgit( mode => 'tcp', collect_exported => false, options => { + 'balance' => 'source', 'option' => [ 'tcplog', ], @@ -260,9 +262,10 @@ class cgit( mode => 'tcp', collect_exported => false, options => { - 'maxconn' => '32', - 'backlog' => '64', - 'option' => [ + 'maxconn' => '32', + 'backlog' => '64', + 'balance' => 'source', + 'option' => [ 'tcplog', ], },