]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
REGTEST: Don't use the websocket to validate http-check
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 5 Jan 2021 14:42:51 +0000 (15:42 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Thu, 28 Jan 2021 15:37:14 +0000 (16:37 +0100)
Now, some conformance tests are performed when an HTTP connection is
upgraded to websocket. This make the http-check-send.vtc script failed for
the backend <be6_ws>. Because the purpose of this health-check is to pass a
"Connection: Upgrade" header on an http-check send rule, we may use a dummy
protocal instead.

reg-tests/checks/http-check-send.vtc

index 3c07e1c746ee7a3a58fab6f96a8640f1964504a7..9773805a010c0d3658eb9e5d44c11c9c635f5986 100644 (file)
@@ -72,11 +72,11 @@ server s6 {
     expect req.proto == HTTP/1.1
     expect req.http.host == "ws-host"
     expect req.http.connection == "upgrade"
-    expect req.http.upgrade == "websocket"
+    expect req.http.upgrade == "raw-proto"
     txresp \
       -status 101 \
       -hdr "connection: upgrade" \
-      -hdr "upgrade: websocket"
+      -hdr "upgrade: raw-proto"
 } -start
 
 
@@ -154,7 +154,7 @@ haproxy h1 -conf {
 
     backend be6_ws
         log ${S6_addr}:${S6_port} len 2048 local0
-        http-check send meth GET uri / ver HTTP/1.1 hdr host ws-host hdr connection upgrade hdr upgrade websocket
+        http-check send meth GET uri / ver HTTP/1.1 hdr host ws-host hdr connection upgrade hdr upgrade raw-proto
         http-check expect status 101
         server srv ${s6_addr}:${s6_port} check inter 200ms rise 1 fall 1