mautic.ERROR: Uncaught PHP Exception

Your software
My Mautic version is: 3.1.2
My PHP version is: 7.3
My Database type and version is: 5.7

Your problem
Besides that Mautic seems to run without errors i find those logs below.
I run Mautic behind a Nginx reverse-proxy and have added
$_SERVER[‘HTTPS’] = ‘on’;
to start of index.php of Mautic.
The SSL-Termination is done at the revprox.

These errors are showing in the log:
[2020-11-11 14:50:43] mautic.ERROR: Uncaught PHP Exception Symfony\Component\HttpKernel\Exception\BadRequestHttpException: “Untrusted Host “89.239.2.123”.” at /systems/mautic/htdocs/vendor/symfony/http-kernel/HttpKernel.php line 71 {“exception”:"[object] (Symfony\Component\HttpKernel\Exception\BadRequestHttpException(code: 0): Untrusted Host “89.239.2.123”. at /systems/mautic/htdocs/vendor/symfony/http-kernel/HttpKernel.php:71, Symfony\Component\HttpFoundation\Exception\SuspiciousOperationException(code: 0): Untrusted Host “89.239.2.123”. at /systems/mautic/htdocs/vendor/symfony/http-foundation/Request.php:1319)"}

:exclamation: Ensure this IP belongs to you. It may be a true CORS request.

If this ip belongs to you follow these steps:

Did you setup CORS in the config section in Mautic? Either remove this feature or add the ip of your Ngnix proxy i.e. 89.239.2.123.
You can alternatively change this in local.php:

You probably have something like this in the local.php
trusted_hosts: - "%domain%"
either remove it or add the IP

Yes, the IP belongs to the Mautic reverse proxy. And i also setup CORS:

    'cors_restrict_domains' => 1,
    'cors_valid_domains' => array(
            '0' => 'https://mautic.my.domain',
    ),

The URL https://mautic.my.domain points to the abovie IP address 89.239.2.123 (of course this i anonymized and not my real address and name, as i do not want to post it here in public).

The trusted hosts is set to:

    trusted_hosts' => array(
    '0' => '.*\\.my\\.domain$'
    ),

of course this i anonymized and not my real address and name, as i do not want to post it here in public

Perfectly understandable. If you ever really need to you can use a PM. But in this case confirming you’ve checked it is enough.

What happens if you add the ip address to your CORS config?