Using custom port for website
Hi
I have domain on cloudflare and 2 websites hosten od my own server.
1 website is on port 80 and its working good.
But i wanted to set secound webside to subdomain (subdomain.domain.net).
the problem is that I cannot add a port in the dns settings and I have no way to redirect users using the subdomain to the correct port so that the correct website is displayed to them
how can I assign the second website running on ip:3000 to a subdomain if possible on cludflare?
5 Replies
The list of supported ports are here:
https://developers.cloudflare.com/fundamentals/reference/network-ports/
Cloudflare Docs
Network ports · Cloudflare Fundamentals docs
Learn which network ports Cloudflare proxies by default and how to enable Cloudflare's proxy for additional ports.
What you can do is set up a reverse proxy and configure a supported port.
Here's a guide: https://www.digitalocean.com/community/tutorials/how-to-configure-nginx-as-a-reverse-proxy-on-ubuntu-22-04
How To Configure Nginx as a Reverse Proxy on Ubuntu 22.04 | Digital...
This tutorial will demonstrate how to set up a reverse proxy using Nginx, a popular web server and reverse proxy solution. You will install Nginx, configure …
if you're on a paid plan you can also use a origin rule
thanks, that's exactly what I needed ❤️