Fwd: Config Guidance
vikrant.thakur at gmail.com
Wed Sep 23 18:22:28 UTC 2015
It seems I sent to wrong mailing list... got no response. So forwarding
this question at "nginx at nginx.org"
---------- Forwarded message ----------
From: vikrant singh <vikrant.thakur at gmail.com>
Date: Tue, Sep 22, 2015 at 12:38 PM
Subject: Config Guidance
To: nginx-forum at nginx.us
I have quick question on config. On my reverse proxy I need to serve both
web-socket and normal http request.
For websocket request I add following in request...
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
And for normal ones I just do
My question is how to unify these two in a single location directive? I can
identify a websocket request and add extra header in a if block. But as
using if is not recommended I am not sure if I should do that.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the nginx