Having issues with IMAP / SMTP - no access, and webmail 500 error

I’ve come to realise that email services stopped working on one of my domains / servers in July 2022. It did work prior to that. I see in my records that I upgraded Cyberpanel to 2.3.1 at that time. I’m not sure what version it was upgraded from though.

Today I updated to v2.3.2 to see if that fixed the issue. It hasn’t changed it. The server runs Ubuntu 18.4.

I have mail.MYDOMAIN.net set up in the DNS as per the instructions for Cyberpanel (detailed here). That only pertains the SMTP, although I’ve set up mail servers and DNS many times before, and I’m pretty sure I’ve got everything right for the IMAP site of things (it uses the same DNS entry, so shouldn’t be much difference to those instructions).

I have issued the SSL for the mail server.

I have used the credentials provided on the mail settings in CP (found on https://cyber.MYSERVER.nz:8090/email/listEmails

In Apple Mail I get “Unable to verify account name or password.”. It’s not a password issue. I’ve reset it, just in case it was wrong.

Both SMTP and IMAP are not able to connect.

I also note that I am no longer able to access to the webmail. It tries to use this URL, and causes a 500 Server Error, https://cyber.MYSERVER.nz:8090/snappymail/

Any assistance is resolving this would be much appreciated.