
87 line golang smtp server that just writes emails to a txt file - andrewfromx
https://github.com/andrewarrow/jungle_smtp
======
0x0
This server doesn't seem to speak SMTP at all, it just logs incoming text
lines to a file until it sees ".\r\n" \- emitting responses for each line as
if the client follows a pre-defined script of (ignored) SMTP verbs?

~~~
andrewfromx
yeah it's very sloppy, but at least u can email info@officecrashe.rs now and
the email doesn't bounce and I get all the info by just reading that file it
writes to. So far I've gotten every test email I've sent. I rented a box at
digital ocean and nothing was running on port 25. So I just slapped that
together. I don't know how to configure postfix.

------
spongeboy
For a better quality Golang mock SMTP server, check out MailHog.

[https://github.com/mailhog/MailHog](https://github.com/mailhog/MailHog)

~~~
andrewfromx
that's awesome! you win on quality hands down. I was writing jungle_smtp in
like a chess clock running, code as fast as you possibly can, cutting every
corner you can, just treat the fact that emails are currently bouncing from my
domain as 100% unacceptable and save all those lost emails. For me it was
definitely faster to code something like jungle than to setup any real smtp
server.

