Proxy subdomain and exclude websockets

I have a domain

that sub domain has two ports opened

[email protected]@ps:// that opens the web application (interface)


something. that is a web socket (secure socket IO, featherJS) server

It works perfectly but I have to disable proxy on Cloudflare (gray cloud)

I decided to use the Load Balancer option of Cloudflare for the https:// to fail over the web app in case of failure but as I understand I have to enable Cloudflare (orange cloud) for this subdomain. If I do this, my clients cannot connect using socket io. The obvious solution would be to separate two services with two domains like

something . example . com for web (ORANGE cloud)
something-node . example . com for socket server (GRAY cloud)

but i can’t since my software is already installed in 5000 pcs and already have hard-coded the same for both cases (web+sockets).

I was wondering if that would be possible to proxy (ORANGE cloud) that subdomain and some how exclude the traffic for port 3030 and redirect to original server. I tried with SRV record but I failed, it looks like I cant really understand how it works or maybe its not the proper way to do it.

Any ideas how to solve it?

I haven’t thought this through, but what about :grey: for, and have your web server forward all http requests to a different subdomain that’s set to :orange:?

if something.example . com is GRAY cloud it will not allow me to use load balancer service on Cloudflare. I want to buy the Load Balancer service for the web app

That’s the point it has to be ORANGE

I don’t see any other way around this, other than Spectrum which is only available to Enterprise users. :orange: does not listen to Port 3030 requests.


I changed my server port from 3030 to 2083 and now they all work (web + sockets), but my question now, sockets are passed through Cloudflare so I have the limits of the plans listed below? Or they are redirected to my server so I have unlimited connections and I don’t have to worry about plan limits?

The end of that article is CF’s general philosophy: Go ahead and use services respectfully. If you head into heavy load territory, they’ll let you know.

If it’s :orange:, then it’s going through Cloudflare. Again, even with 5000 PCs out there, they’re probably not running full speed all the time. And considering you’re probably not running a heavy duty server, your server will bog down before Cloudflare notices an issue.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.