可用于测试和开发的本地 SMTP 服务器 - 实际上不会传递邮件 [英] Local SMTP server that can be used for testing and development - won't actually deliver mail

查看:186
本文介绍了可用于测试和开发的本地 SMTP 服务器 - 实际上不会传递邮件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我正在开发发送电子邮件的东西时,我有时并不想实际发送任何电子邮件,但我确实想看看使用实时数据会发送哪些电子邮件.但是,没有一个简单的方法可以做到这一点,因为我还没有找到一个本地 SMTP 服务器来接收我的邮件,然后将它保存在队列中以便我查看它.

When I'm developing something that sends email, I sometimes don't want to actually send any email, but I do want to see what email would be sent using live data. However, there's not an easy way to do this, as I haven't found a local SMTP server that will receive my mail and then just hold it for me in a queue so I can view it.

在 Windows XP 和 Vista 中,我使用本地安装的 SMTP 服务器并将其设置为传送到不存在的智能主机 - 邮件只是永远位于inetputmailrootqueue"文件夹中,而我可以随时查看.然而,在 Windows 7 中,不再有集成的 SMTP 服务器,虽然我发现了许多可以在本地安装并为我中继邮件的 SMTP 服务器,但我想要一个不会中继邮件.

In Windows XP and Vista, I used the locally installed SMTP server and just set it to deliver to a smart host that didn't exist - the mail just sat in the "inetputmailrootqueue" folder forever, and I could view it whenever I wanted to. However, in Windows 7, there's no longer an integrated SMTP server, and though I've found a number of SMTP servers that can be installed locally and relay mail for me, I want one that won't relay mail.

有人对如何完成此功能有建议吗?我考虑过自己编写,但是如果有什么东西的话,实现整个 RFC 规范似乎是一项艰巨的任务.也许有一个开源项目,我可以修改它只是将邮件写入磁盘而不是传递它.

Does anybody have suggestions on how to accomplish this functionality? I've considered writing my own, but implementing the whole RFC spec seemed like a big task if there's something out there. Maybe there's an open-source project that I could modify just to write the mail to disk instead of delivering it.

推荐答案

Papercut 可能是你想要的,尽管它仅与 Windows 兼容.

Papercut is likely what you want, though it is only compatible with Windows.

这篇关于可用于测试和开发的本地 SMTP 服务器 - 实际上不会传递邮件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆