Closed vthorsell closed 1 year ago
You should be able to do this with the nginx header module:
location /ws_subscriber {
nchan_subscriber;
nchan_channel_id foo;
add_header Sec-WebSocket-Protocol "$http_sec_websocket_protocol";
}
(I haven't tested it, but it should work. please let me know if it does not.)
Hi, is it possible to define a reply to a new subscriber with the same subprotocol used in the connection Sec-WebSocket-Protocol?
i.e. I have certain connections that demand in the reply/authorize that Sec-WebSocket-Protocol is set to the same value as provided in the request, nothing else would need to be changed that just being able to reply with either specified reply or the same replay as used in the connection.