I recently found out that the mails of the last 2 weeks could not sent by InvoiceNinja because our mail gateway could not be reached.
The Mail config in the .env file looks like this:
MAIL_HOST=192.168.1.2
MAIL_PORT=2225
MAIL_FROM_ADDRESS="[email protected]"
MAIL_FROM_NAME="My Company"
In the Logfile ./storage/logs/invoiceninja.log we have the messages:
[2024-08-07 11:00:40] production.INFO: Trying to send to [email protected] 2024-08-07 11:00:40
[2024-08-07 11:00:40] production.INFO: Using mailer => smtp
[2024-08-07 11:00:40] production.INFO: Mailer failed with Connection could not be established with host “192.168.1.2:2225”: stream_socket_client(): Unable to connect to 192.168.1.2:2225 (Connection refused)
But in the react web app I did not get an error message when sending the mail. No timeout or anything, it just looked like the mail was successfully sent.
Why am I not getting an error here? Do I have to change our configuration somehow?