Nethserver fresh install, Owncloud redirects to local host

Hello everyone,
yesterday i made a fresh install of nethserver and i installed owncloud. I was able to access it using the ip (x.x.x.x/owncloud) but after trying to connect using an external dns (free from the server would redirect me to and address like https://hostname.domain/owncloud which doesn’t work either on LAN or from the internet. After that i couldn’t connect to the local ip either. I reinstalled nethserver today but this happened from the beginning. I can’t even connect to the local ip now as it redirects me yet again.

If i don’t type /owncloud at the end either from LAN or externally it connects to the apache test page correctly so i’m guessing it’s an owncloud problem. I also added the domain as a trusted host in owncloud using the two commands found in documentation.

Your help is much appreciated as this is a server used at work and at the moment we’re out of cloud. Thanks in advance!

Hi @LamboLighting,

In order to help you please share next info:

  1. domain name
  2. network config
  3. screenshot with errors

You need to add the public name to “Trusted domains”.


From the server name page on the nethserver site:
Hostname: pav-security
Domain: pav-server.lan

eth0: Role LAN (green)

The error is that when i type my public name into the browers, let’s say it redirects straight away to https://pav-security.pav-server.lan/owncloud/
but if i type i get connected to the test page of apache.


I have added the public name to the trusted domains but still nothing.

This is a built-in function of Owncloud itself, not NethServer:

We provide a work around for it. If your public name is

config setprop owncloud TrustedDomains
signal-event nethserver-owncloud-update

Take a look to trusted_domains option inside /var/www/html/owncloud/config/config.php

As i said i added the public name to the trusted domains using the commands you mentioned.
It looks like:

'trusted_domains' =>
array (
0 => '',
1 => 'pav-security.pav-server.lan',
2 => '',
3 => '',


The second example site is due to another public name.

It still does the same thing.

I’ve finished my ideas :open_mouth: , it seems much a Owncloud problem…

Maybe @alep and @alefattorini know how to fix it?

As i said it’s a fresh install of nethserver, only thing i did was install owncloud, mysql and webserver through the software center and add the trusted domains. Nothing else at all. I also updated everything through ssh before doing anything at all.

Hi, I had the same problem.
if you call and NetServer is configured for use only https, NethServer redirect you to https://pav-security.pav-server.lan/owncloud. if you call it work (in my case).

Alternatively you can try to call the NetServer with the public name (

I usually typed it without http or https. After trying both http redirects instantly and https times out after some time.
Not only on but also on which works correctly with http. Maybe it has something to do with this?

Oh my god, it was too easy but who would have thought.
My ISP had messed up the ports on the router last time they tried to fix something so the port wasn’t actually assigned to the server although it seemed like it was. It now works correctly.

Thanks everyone for your time!