How create a subdomain pointing to an ip and a port?


#1

Hi !

I recently setup an OpenMediaVault server to get a homemade NAS.

To be able to access the various services offered by my NAS, I am required to enter the IP address of the server followed by the port associated with the service.

For example, to access my cloud (Nextcloud), I must enter this address in the browser: https://xx.xxx.xxx.xxx:444

My question is: is it possible to create a subdomain pointing to an ip and a port?

For example, I would like to be able to access my cloud (xx.xxx.xxx.xxx.xxx.xxx:444) by entering: https://cloud.mydomain.com

Because after several searches I understood that I didn’t. I even tried to create an SRV record but it doesn’t work.

Or is there another alternative?

Thank you in advance for your answers.

PS: sorry for my approximate English :slight_smile:


#2

DNS and ports are two separate and unrelated things.

Cloudflare only supports the ports listed at https://support.cloudflare.com/hc/en-us/articles/200169156-Which-ports-will-Cloudflare-work-with-, also pay attention to the separation of HTTP and HTTPS ports.

You’d need to configure your NAS to run on one of these ports or alternatively - depending on your network setup - have some port translation/remapping.


#3

Thank you for your quick answer!

Yes, that’s what I understood when I did my research.

I will replace the application port with one of the ones listed in your link.

But how do I create the subdomain in Cloudflare with this port?

Because on my NAS I have several applications on different ports, how can I access them with a sub-domain specific to each one?

Example:


#4

As I mentioned earlier, DNS and ports are unrelated. You dont create “a host with a port”. You simply add the desired A record in your control panel with the right name and IP address, which you can then connect to specifying th right port in your browser.


#5

Yes, I understand.

So I can’t create several subdomains for each of the services on my NAS? Only one?


#6

You can create as many as you want, but they will all point to the same IP address and you’ll still need to append the port to the host in the address bar.


#7

All right, no problem.

On the other hand, I get this error 526 (invalid SSL certificate):

How to solve this problem? Because certification only works for addresses:


#8

Ok, I solve my problem.

I replaced the SSL Status “Full Strict” with just "Full’ :slight_smile:


closed #9

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