Yet another Trusted domain issue

I apologize that there is lot of information on trusted domains but I cannot seemed to solve my issue. I have a lan my house where I have set up a nextcloud server on a raspberry pi 4 running a sqlite database. Because I have several machines I am not got at remembering all the ip addresses.
I would like to point laptop to my nextcloud server using its host name and not its ip. But when I type myserver/nextcloud I get the Access through untrusted domain error. I have the ip of the server in the config.php file I even added the ip of my laptop but to no avail. I can access the server externally using the domain I have set up for a webserver and port-fowarding but internally the only way I can access the nextcloud server is using it ip address. Can this be resolved somehow?

You need to employ either hairpin NAT or split-horizon DNS so that connections to your hostname terminate to the host on your LAN.

Thanks for the reply, having googled both hairpin NAT and split horizon DNS it looks a little complicated for me a simple hobbyist. Perhaps I will just have to learn so suffer using the ip addresses alone. Is there a away to make the config.php ignore the trusted domain settings?

As you are talking about nextcloud you might want to ask on the nextcloud forum?

No, it can’t be disabled.

In that case, you have to add the hostname of your server to the trusted domains, not the IP address of your laptop.

1 Like

Enabling hairpin NAT is usually just a checkbox in a router configuration, assuming the device supports it.

Running split DNS doesn’t have to be complicated either. It can be as simple as adding local data for your ownCloud server hostname to a local unbound resolver.

Neither option should be considerably more difficult than running ownCloud.

I did try that by putting the name of the server in the config.php file but that did not seem to work -

Thanks for this information, I cannot seem to find the setting for hairpin on my router which is an Actiontec. I will have to look further for setting up local data for your ownCloud server hostname to a local unbound resolver.

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