Can't create user when SMTP is enabled #87

Open
opened 2026-02-16 12:51:24 -05:00 by yindo · 3 comments
Owner

Originally created by @michelleDeko on GitHub (Jan 22, 2025).

Hi,

I tried setting up Revolt on my server with an SMTP server (mailcow on the same server)
But I can't register an account because of the following error:

INFO  rocket::server                                                   > POST /auth/account/create application/json:
 INFO  rocket::server::_                                                > Matched: (create_account) POST /auth/account/create
 ERROR authifier::config::email_verification                            > Failed to send email to michelle@miichelle.moe!
lettre error: Connection error: Network is unreachable (os error 101)
 INFO  rocket::server::_                                                > Outcome: Success(500 Internal Server Error)
 WARN  rocket::server::_                                                > Remote left: client disconnect before response started.

I'm 100% sure I the smtp settings were set correctly.
This is the error I'm getting on the website:

Image

I also saw this error in the browser console:

Image

Is there a way to fix this?

Originally created by @michelleDeko on GitHub (Jan 22, 2025). Hi, I tried setting up Revolt on my server with an SMTP server (mailcow on the same server) But I can't register an account because of the following error: ``` INFO rocket::server > POST /auth/account/create application/json: INFO rocket::server::_ > Matched: (create_account) POST /auth/account/create ERROR authifier::config::email_verification > Failed to send email to michelle@miichelle.moe! lettre error: Connection error: Network is unreachable (os error 101) INFO rocket::server::_ > Outcome: Success(500 Internal Server Error) WARN rocket::server::_ > Remote left: client disconnect before response started. ``` I'm 100% sure I the smtp settings were set correctly. This is the error I'm getting on the website: ![Image](https://github.com/user-attachments/assets/68a69000-6dbe-41de-85de-adfae1d0e401) I also saw this error in the browser console: ![Image](https://github.com/user-attachments/assets/96d49077-220b-4014-b457-660321e90168) Is there a way to fix this?
Author
Owner

@insertish commented on GitHub (Feb 9, 2025):

It appears to be struggling to connect to your mail server, have you verified the connection manually?
If you specify "localhost", it won't work because that will refer to the internal Docker network.
You can use this trick for example: https://stackoverflow.com/a/62431165

@insertish commented on GitHub (Feb 9, 2025): It appears to be struggling to connect to your mail server, have you verified the connection manually? If you specify "localhost", it won't work because that will refer to the internal Docker network. You can use this trick for example: https://stackoverflow.com/a/62431165
Author
Owner

@michelleDeko commented on GitHub (Feb 9, 2025):

It appears to be struggling to connect to your mail server, have you verified the connection manually? If you specify "localhost", it won't work because that will refer to the internal Docker network. You can use this trick for example: https://stackoverflow.com/a/62431165

I used the domain name (mail.domain.com), not something local. I also used the same options like I do in Nextcloud for example.

@michelleDeko commented on GitHub (Feb 9, 2025): > It appears to be struggling to connect to your mail server, have you verified the connection manually? If you specify "localhost", it won't work because that will refer to the internal Docker network. You can use this trick for example: https://stackoverflow.com/a/62431165 I used the domain name (mail.domain.com), not something local. I also used the same options like I do in Nextcloud for example.
Author
Owner

@Tyrthurey commented on GitHub (Feb 9, 2026):

++ on this, tried to set it up with resend smtp, but no luck

@Tyrthurey commented on GitHub (Feb 9, 2026): ++ on this, tried to set it up with resend smtp, but no luck
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: stoatchat/self-hosted#87