Mailpit acts as an SMTP server and also provides a web interface to view all captured emails.
We use the official Mailpit image.
When PHP sends emails using sendmail or SMTP, it's automatically "caught" by Mailpit. This enables you to review the emails without delivering them to real email addresses.
You can view anything which has been caught at http://localhost:8025/.
You can configure any SMTP client (such as PHP applications) to use Mailpit.
Parameter | Value |
---|---|
Host | mailpit (from a container)localhost (from your computer) |
Port | 1025 |