[4.1] dd050f0 Reword and update code
Lasse Karstensen
lkarsten at varnish-software.com
Thu Jan 14 15:15:07 CET 2016
commit dd050f03e07fb1e7a1dab6e33b28285fc148f630
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