[master] a30c474 Reword and update code
Federico G. Schwindt
fgsch at lodoss.net
Fri Nov 27 21:00:55 CET 2015
commit a30c474e09ed6d8af1bd6a2da7a7574a5ef1407f
Author: Federico G. Schwindt <fgsch at lodoss.net>
Date: Fri Nov 27 19:59:05 2015 +0000
Reword and update code
diff --git a/doc/sphinx/users-guide/vcl-example-websockets.rst b/doc/sphinx/users-guide/vcl-example-websockets.rst
index 609fe61..24ea561 100644
--- a/doc/sphinx/users-guide/vcl-example-websockets.rst
+++ b/doc/sphinx/users-guide/vcl-example-websockets.rst
@@ -1,21 +1,14 @@
-Implementing websocket support
-------------------------------
+Adding WebSockets support
+-------------------------
-Websockets is a technology for creating a bidirectional stream-based channel over HTTP.
+WebSockets is a technology for creating a bidirectional stream-based
+channel over HTTP.
-To run websockets through Varnish you need to pipe it, and copy the Upgrade header. Use the following
-VCL config to do so::
+To run WebSockets through Varnish you need to pipe it as follows::
- sub vcl_pipe {
- if (req.http.upgrade) {
- set bereq.http.upgrade = req.http.upgrade;
- }
- }
sub vcl_recv {
- if (req.http.Upgrade ~ "(?i)websocket") {
- return (pipe);
- }
+ if (req.http.upgrade ~ "(?i)websocket") {
+ return (pipe);
+ }
}
-
-.. XXX: Pipe it? maybe a bit more explanation here? benc
More information about the varnish-commit
mailing list