diff --git a/doc/configuration.txt b/doc/configuration.txt index 832b618b0..57c04f5d5 100644 --- a/doc/configuration.txt +++ b/doc/configuration.txt @@ -18215,9 +18215,8 @@ check-reuse-pool any specific check connect option is defined, either on the server line or via a custom tcp-check connect rule. - If checks are activated for a reverse HTTP server, this option is mandatory - for checks to succeed, as by definition these servers do not have the ability - to initiate connection. + This option is automatically enabled for servers acting as passive reverse + HTTP gateway, as for those servers connect is only supported through reuse. check-send-proxy May be used in the following contexts: tcp, http diff --git a/src/server.c b/src/server.c index a6892bcea..4af5ce2d2 100644 --- a/src/server.c +++ b/src/server.c @@ -2852,7 +2852,8 @@ void srv_settings_cpy(struct server *srv, const struct server *src, int srv_tmpl srv->check.sni = src->check.sni; srv->check.alpn_str = src->check.alpn_str; srv->check.alpn_len = src->check.alpn_len; - srv->check.reuse_pool = src->check.reuse_pool; + if (!(srv->flags & SRV_F_RHTTP)) + srv->check.reuse_pool = src->check.reuse_pool; /* Note: 'flags' field has potentially been already initialized. */ srv->flags |= src->flags; srv->do_check = src->do_check; @@ -3505,6 +3506,8 @@ static int _srv_parse_init(struct server **srv, char **args, int *cur_arg, } else { newsrv->flags |= SRV_F_RHTTP; + /* Automatically activate check-reuse-pool for rhttp@ servers. */ + newsrv->check.reuse_pool = 1; } }