HTTP/2 configuration help needed



I’ve found a few examples such as that detail how to setup HTTP/2 and HTTP/1.1 co-existence.

But they seem to be limited to using SSL.

In particular, the examples I’ve found seem to use :

use_backend nodes-http2 if { ssl_fc_alpn -i h2 }

As a test for whether a client supports HTTP/2. What is the equivalent to use for plain old HTTP ?

Thanks !


ALPN negotiated HTTP or any HTTP?

I would suggest to use a fallback for HTTP (default_backend), otherwise non ALPN capable clients won’t match.

Otherwise, just match the ALPN value, which is http/1.1 ( { ssl_fc_alpn -i http/1.1 } ).


Well, if it means anything, you can assume I have no plans to install SSL certs on HA proxy, as it is proxying for an HTTP only service at this stage, and my vague understanding is that ALPN needs certs.


There is not support for unencrypted HTTP/2.0 in any browsers on the market today, so this doesn’t make any sense.