I have NextCloud server running everything is working fine except the IMAP configuration of the mail client. When trying to log in to my local MailCow mail server I get an error: IMAP server is unreachable. When I try to configure another mail account located outside my LAN the configuration works fine. From the NC CLI console, PING to the address of my local mail server by both local IP and external URL works correctly.
The DNS query is executed by Windows Server 2022, and the URL redirection to the local IP address is set there.
The NC server is behind the ZORAXY reverse proxy, but this should not affect IMAP communication.
It looks like the NC server could not correctly resolve the DNS query coming from Windows Server 2022. Previously, Exchange Server 2019 was at the mail address and local IP address and the connection worked fine. Now only after changing to MailCow I cannot connect to it from NC.
I’m not sure if disabling TLS verification is safe.
No it’s not.If you deactivate the TLS check, you should be aware that this makes the connection fundamentally more vulnerable - even in the local network, this can pose a risk. This is sometimes fine for test purposes, but it is not recommended on a permanent basis.
You might consider creating a cert with mcert
and google howto harden your mailserver with it, or any other ways to trust a local cert but,
My personal recommendation:
Avoid permanently deactivating the TLS check at all costs!