DigitalOcean 应用平台上的传出 SMTP 超时

Outgoing SFTP Timeouts on DigitalOcean App Platfrom

我有一个 Node 应用程序需要将(少量的)XML 文件转储到外部 SFTP 服务器。我正在使用 'sftp-sync-deploy' SFTP 同步库,该应用程序在本地运行良好,但一旦部署到 DigitalOcean 应用程序平台,我就会遇到 SFTP 超时,而不是上传。

错误如下所示:

[12:06:18] Server running on port 5000
[12:07:16] syncIxRS called
[12:07:16] * Deploying to host homeXXXXXXX.1and1-data.host
[12:07:16] * local dir  = /workspace/ixrs
[12:07:16] * remote dir = 
[12:07:16] 
[12:07:36] Error syncing IxRS folders Error: Connection Error: Timed out while waiting for handshake
[12:07:36]     at Client.<anonymous> (/workspace/node_modules/sftp-sync-deploy/lib/sftpSync.js:61:28)
[12:07:36]     at Client.emit (events.js:314:20)
[12:07:36]     at Timeout._onTimeout (/workspace/node_modules/ssh2/lib/client.js:689:14)
[12:07:36]     at listOnTimeout (internal/timers.js:554:17)
[12:07:36]     at processTimers (internal/timers.js:497:7)

我的假设是传出 SFTP 请求或传入响应被阻止,但我看不到如何在 DigitalOcean 端打开此端口。

我最近 运行 也关注这个问题。 DigitalOcean 支持给出了这个答案:

Unfortunately the SFTP protocol which uses SSH is not supported in app platform. Only TCP connections can be made external to app platform. App platform's disk is also ephemeral so any content moved there would be lost on each deploy.

不幸的是,SSH(以及 SFTP)在 App 平台中根本不可用。