Testing Mailpit
These instructions provide an easy way to “send” a test email to Mailpit to ensure it is working.
This assumes Mailpit is running, and is listening on port 1025 (default).
Create a text file email.txt with the following contents.
Then run the following command to “send” your test email:
mailpit sendmail < email.txt
If you are using a system-installed version of sendmail, your command may look like this:
sendmail -t -S localhost:1025 < email.txt
Please note that various packages provide different implementations of sendmail, and they all work slightly different to each other,
so please refer to the help of your version of sendmail.
Test using telnet
You can also send an email directly to Mailpit using telnet:
Edit this page