ftp-deploy icon indicating copy to clipboard operation
ftp-deploy copied to clipboard

error in deploy:Timed out while making data connection

Open behnammodi opened this issue 7 years ago • 9 comments
trafficstars

const path = require('path');
const FtpDeploy = require('ftp-deploy');
const ftpDeploy = new FtpDeploy();

const buildPath = path.join(__dirname, '..', 'build');

const log = (...args) => {
    console.log('→', ...args);
}

const config = {
    user: 'XXXX',
    password: 'XXXX',
    host: 'XXXX',
    port: 21,
    localRoot: buildPath,
    remoteRoot: './',
    include: ['*', '**/*'],
    exclude: [],
}

ftpDeploy.deploy(config)
    .then(res => log('📦', ' deploy finish'))
    .catch(err => log('📦', ' deploy error', err));

ftpDeploy.on('uploading', data => {
    log('‌📦', ` uploading ${parseInt((data.transferredFileCount / data.totalFilesCount) * 100)}% (${data.transferredFileCount}/${data.totalFilesCount})`, data.filename);
});

but with this config work on yummy ftp pro app

behnammodi avatar Aug 19 '18 05:08 behnammodi

Also received this error.

RuslanGrigoryev avatar Oct 02 '18 09:10 RuslanGrigoryev

Can you say what happened, and what you expected to happen. I don't try to do much about time outs as they are out of my control

simonh1000 avatar Oct 02 '18 10:10 simonh1000

In #62 a possibly similar error was solved by adding forcePasv: true to the config - do you want to try that

simonh1000 avatar Oct 13 '18 17:10 simonh1000

@simonh1000 yes i try that and say result

behnammodi avatar Oct 13 '18 17:10 behnammodi

@RuslanGrigoryev yes

behnammodi avatar Oct 13 '18 18:10 behnammodi

I had a similar problem (just no progress and no error or timeout) before rolling back to node 7.4. Also I installed natives (https://github.com/addaleax/natives) what may cause this error.

blaues0cke avatar Nov 26 '18 10:11 blaues0cke

Also has this error, flag forcePasv is value true

idushii avatar Mar 03 '19 04:03 idushii

我也遇见同样的问题,这是由于服务器的安全设置造成的。 解决方法:

  1. 使用PORT模式连接。
  2. PORT模式端口范围设置为1024-2048。

请问如何在ftp-deploy中配置以上内容?

I had the same problem with the server's security Settings. Solutions: Connect using PORT mode. The PORT mode PORT range is set to 1024-2048. How to configure the above contents in ftp-deploy?

acccccccb avatar Aug 14 '19 02:08 acccccccb

its still giving error while making forcePasv: true, Err Timed out while making data connection Error: Timed out while making data connection at Timeout. (/Projects/magicrm-repo/node_modules/@icetee/ftp/lib/connection.js:962:12

manishaquil avatar May 16 '22 11:05 manishaquil

try to set forcePasv: false

ygweric avatar May 06 '24 06:05 ygweric