您可以执行以下操作来防止大量泄露:
- 在另一台 VPS 上设置一个代理服务器,例如 Tinyproxy
- 设置环境变量
HTTPS_PROXY和HTTP_PROXY,以便 Discourse 使用它(在app.yml的env部分设置它们) - 设置
NO_PROXY='127.0.0.1, localhost, <internal-network>'
另请参阅 https://meta.discourse.org/t/install-discourse-with-internet-access-only-via-proxy/66396/、https://meta.discourse.org/t/configuration-outbound-proxy/65992 和 Discourse Link previews through a proxy server? - #14 by supermathie
此外,当您使用 CF 时,您可以修改 Discourse 主机上的防火墙,使其仅允许来自您的 Cloudflare IP(以及您自己访问它的主机)的入站流量。