Logging loop after a new domain name

Expected behaviour

Good morning, sir,
I just had one of my domain names pointed to my owncloud server but I can no longer connect (logging loop) to my owncloud user when I try with the address http://domainename.fr/owncloud.
Yet when I try with ipadress/owncloud I manage to connect.

Server configuration

Debian 9

The content of config/config.php:

<?php $CONFIG = array ( 'updatechecker' => false, 'instanceid' => X, 'passwordsalt' => X, 'secret' => 'X', 'trusted_domains' => array ( 0 => 'Serv IP', 1 => 'domainename.fr', ), 'datadirectory' => '/var/www/owncloud/data', 'overwrite.cli.url' => 'domaine.fr', 'force ssl' => true, 'dbtype' => 'mysql', 'version' => '10.3.2.2', 'dbname' => 'owncloud', 'dbhost' => 'localhost', 'dbtableprefix' => 'oc_', 'dbuser' => 'X', 'dbpassword' => 'X', 'logtimezone' => 'UTC', 'apps_paths' => array ( 0 => array ( 'path' => '/var/www/owncloud/apps', 'url' => '/apps', 'writable' => false, ), 1 => array ( 'path' => '/var/www/owncloud/apps-external', 'url' => '/apps-external', 'writable' => true, ), ), 'installed' => true, 'loglevel' => 0, ); [/quote] When I am logging with the domain URL I have that in the URL : http://myhomecloud.fr/index.php/login?redirect_url=%252Findex.php%252Fapps%252Ffiles Thanks a lot !