# 为自托管站点配置带 Mail-Receiver 的直接投递入站邮件

**URL:** <https://meta.discourse.org/t/configure-direct-delivery-incoming-email-for-self-hosted-sites-with-mail-receiver/49487>\
**Category:** Self-Hosting\
**Tags:** email, how-to, advanced-setup, mail-receiver\
**Created:** [2016年八月31日 10:58 UTC](https://meta.discourse.org/t/configure-direct-delivery-incoming-email-for-self-hosted-sites-with-mail-receiver/49487 "2016-08-31T10:58:09Z")\
**Posts on this page:** 1\
**Showing post:** 533

<div class="post-metadata">

**Author:** ![Ethsim2](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ethsim2/32/522255_2.png) [@Ethsim2](https://meta.discourse.org/u/Ethsim2)\
**Post date:** [2025年五月18日 21:06 UTC](https://meta.discourse.org/t/configure-direct-delivery-incoming-email-for-self-hosted-sites-with-mail-receiver/49487/533 "2025-05-18T21:06:14Z")

</div>

我在 ufw 中发现需要打开 443 端口 — 否则，我在 `logs` 中会遇到 `API Request Preparation Failed`。我认为最好提及这一点，因为标准的安装说明提到了启用 ufw。

> [@](#):
>
> [新手安装指南](https://github.com/discourse/discourse/blob/main/docs/INSTALL-cloud.md)
> 
> • 如果您需要或想要一个默认防火墙，请在 Ubuntu 上启用 ufw

`mail-receiver.yml` 中提到了 25 端口，它似乎绕过了 ufw。

---

_[View the full topic](https://meta.discourse.org/t/configure-direct-delivery-incoming-email-for-self-hosted-sites-with-mail-receiver/49487)._
