I believe you'll need an nginx server block for each domain. In the second domain, use the nginx rewrite directive to change the url, anywhere before the proxy_pass directive.
Cloudflare Websocket Support: Capacity?
I found the link at the end of this article stating that Cloudflare supports websockets. They claim that the volume of concurrent connections for the free pack is low. How does this translate to NodeBB? Currently I'm using a setup as follows:
NodeBB + Mongo -> nGinx
-> ws.[domain] for websockets
-> www/@.[domain] with Cloudflare
Would you recommend leaving the websocket subdomain with DDoS protection in mind, and switch to Cloudflare-powered websockets as a whole? Does anyone have experience with Cloudflare's websocket tunnels?
From what the article says, it sounds like there is no hard limit, and the point at which they will warn you about over-usage is relative to other users on the plan. So, I would guess that, unless you have a site large enough that it will generate enough revenue for the larger plan, then your site will never even come close to the "limit".
For your second question, I would leave the subdomain and switch it over to orange. I did that, and my websocket heavy content subjectively loads much faster.
Thank you for the suggestion! I didn't think about switching the subdomain do cloudflare-powered