Platform: TRUENAS-MINI-3.0-X+
Version:Dragonfish-24.04.2
Please bear with me, I am new to TrueNAS
Nextcloud App Version: 29.0.4
Chart Version: 2.0.11
Hi.
I have set up the Nextcloud app but have no knowledge as to how the whole thing works in the background (Apache, nginx, …), nor where any configuration files are located.
I need to access Nextcloud from the internet and the LAN. On my firewall everything is set up (NAT port fowarding etc) and is not the issue, a previous installation of Owncloud works fine.
My problem is this:
When I connect to Nextcloud using the FQDN (mydomain.com:myncport) I see the login page OK. I then enter my id/pw, and click Log in.
The browser is immediately redirected to the login page again but in the URL field I see the LAN IP of Nextcloud instead of the FQDN. I can then enter my id/pw again and the connection works.
Note: this redirection does not happen when I connect to the Truenas GUI (mydomain.com:443) - the browser stays on the FQDN, so I gather that my problem is particular to Nextcloud.
This redirection is fine as long as I am on the LAN with the connecting device, but the connection will obviously fail when I try to connect from the internet, as the LAN IP is not reachable.
Can anyone help me understand why this redirection to the LAN IP happens and how to avoid it?
I applied solutions found elsewhere like setting overwrites in /mnt/mydatapool/nextcloud/appdata/config/config.php and restarting Nextcloud but that did not help.
These are the overwrites I set:
‘overwrite.cli.url’ => ‘https://mydomain.com’,
‘overwritehost’ => ‘mydomain.com:myncport’,
Please advise.