change websocket address

For discussion of the Poker Mavens server module and other administration topics
Post Reply
hootan
Posts: 3
Joined: Mon Apr 06, 2020 1:43 pm

change websocket address

Post by hootan »

i have two domain name and i need to use one as http/https address and the other as websocket (ws) address,
how can i do that?
Kent Briggs
Site Admin
Posts: 5878
Joined: Wed Mar 19, 2008 8:47 pm

Re: change websocket address

Post by Kent Briggs »

The websocket domain/IP has to match the app domain/IP. Why would you want to do that?
hootan
Posts: 3
Joined: Mon Apr 06, 2020 1:43 pm

Re: change websocket address

Post by hootan »

because i want to run my app on my pc and use tunnel to forward my users to my pc,
my tunnel app is like ngrok
Kent Briggs
Site Admin
Posts: 5878
Joined: Wed Mar 19, 2008 8:47 pm

Re: change websocket address

Post by Kent Briggs »

hootan wrote:because i want to run my app on my pc and use tunnel to forward my users to my pc,
my tunnel app is like ngrok
I don't know what ngrok is but I still don't see what you are trying to accomplish.
hootan
Posts: 3
Joined: Mon Apr 06, 2020 1:43 pm

Re: change websocket address

Post by hootan »

ngrok is tunnel forwarder,
it make a random domain to share between your users,
so you can use your personal pc as server and share your hosting on that random domain.
but for each port it make a random domain, so if my client want to connect to my server as websocket it should connect to my second random domain.
Kent Briggs
Site Admin
Posts: 5878
Joined: Wed Mar 19, 2008 8:47 pm

Re: change websocket address

Post by Kent Briggs »

Even if that was possible in Poker Mavens (it is not), I suspect most browsers would reject the websocket attempt because it would violate their same-origin policy.
Post Reply