Score:0

Why the Apache2 is not redirecting the Websocket traffic?

vn flag

A web browser uses the following command to connect to server 1:

var websocket = new WebSocket("wss://mywebsite.com:6789/);

server 1 should redirect all the websocket traffic to server 2 which has the IP address of 10.8.0.1. Therefore, on server 1 the Apache config file has the following lines:

<VirtualHost *:6789>

    SSLEngine on
    SSLCertificateFile "/home/ubuntu/ssl/public.key"
    SSLCertificateKeyFile "/home/ubuntu/ssl/private.key"

    <Location "/">
       ProxyPass "wss://10.8.0.1:6789"
       ProxyPassReverse "wss://10.8.0.1:6789"
    </Location>

</VirtualHost>
                

However, the browser gives error and cannot establish the websocket connection. I monitored the network traffic on server 1 with sudo tshark -f "tcp port 6789". There is a traffic on port 6789 coming to server 1 but no websocket traffic going out of server 1 to server 2. What is the source of issue?

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.