STUN Reporting wrong WAN IP

NextCloud: 22.2.3
Hansson IT OVA setup on Ubuntu 20.04.2

I own a block of static WAN IP addresses.
The Wan to LAN traffic is on ..187.11
The Web traffic is going out the gateway at ..187.13

NextCloud and all the Certificates all work properly, The issue is that since the web traffic is going out the gateway it reports that the static ip is dot13. This causes the STUN server to incorrectly report the dot13 wan static ip address to the tallk devices.

I was able to confirm the STUN server reporting the wrong IP using the tool below. Attached is a screenshot.
stun test

Since this is a STATIC wan IP address am I able to set this manually in the STUN server to the correct ip address of the nextcloud instance of dot11?

Some Pictures of the URLS resolving correctly.
Cloud Main URL


Talk URL


Let me know if you have any questions!
Thank you

The root cause is an internal system can only detect it’s public IP by sending request to some external system like - and this external system reports back from which IP it receives your traffic.

I would recommend you to send the traffic out through the same IP as you expect it to enter - otherwise you will hit issues like this because of asynchronous routing when systems e.g. firewall unable to recognize two directions of one communication belong together because the endpoints are not on the same IP.

In other words you either should change your DNS records to …187.13 or make outgoing traffic to exit on …187.11