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

Lack of documentation

Open grenierdev opened this issue 10 years ago • 13 comments

grenierdev avatar Jul 30 '14 00:07 grenierdev

Would be highly appreciated, because right now I don't know how to use your package.

buschtoens avatar Jan 18 '15 23:01 buschtoens

@buschtoens I added a Getting started in the readme that should get you up and ready.

grenierdev avatar Jan 19 '15 01:01 grenierdev

Thank ya,

The problem is, I already tried exactly that. But nothing seems to happen. I use Windows 8.1 64bit.

buschtoens avatar Jan 19 '15 02:01 buschtoens

Can you elaborate on what step does nothing?

  • Remote-FTP not present in Packages : try disabling/enabling the plugin
  • Sidebar not toggling : try reload the editor with CTRL+ALT+R
  • Connect does nothing : if your using FTP, open the console CTRL+ALT+I and search the FTP log for error

grenierdev avatar Jan 19 '15 02:01 grenierdev

@buschtoens might be related to #21

grenierdev avatar Jan 22 '15 18:01 grenierdev

Sorry for not responding sooner. Will look into that this evening. Am 22.01.2015 19:17 schrieb "Michael Grenier" [email protected]:

@buschtoens https://github.com/buschtoens might be related to #21 https://github.com/mgrenier/remote-ftp/issues/21

— Reply to this email directly or view it on GitHub https://github.com/mgrenier/remote-ftp/issues/7#issuecomment-71069557.

buschtoens avatar Jan 23 '15 12:01 buschtoens

@mgrenier

In regards to

Configuration file : node-ftp, TLS, ssh2

How about a section documenting both config types and then borrow the descriptions off of node-ftp and ssh2's respective options and inline them as comments and edit as needed. For example:

SFTP Configuration Options

{
    "protocol": "sftp",
    "host": "example.com", // string - Hostname or IP address of the server. Default: 'localhost'
    "port": 22, // integer - Port number of the server. Default: 22
    "user": "user", // string - Username for authentication. Default: (none)
    "pass": "pass", // string - Password for password-based user authentication. Default: (none)
    "remote": "/",
    "agent": "", // string - Path to ssh-agent's UNIX socket for ssh-agent-based user authentication. Windows users: set to 'pageant' for authenticating with Pageant or (actual) path to a cygwin "UNIX socket." Default: (none)
    "privatekey": "", // mixed - Buffer or string that contains a private key for either key-based or hostbased user authentication (OpenSSH format). Default: (none)
    "passphrase": "", // string - For an encrypted private key, this is the passphrase used to decrypt it. Default: (none)
    "hosthash": "", // string - 'md5' or 'sha1'. The host's key is hashed using this method and passed to the hostVerifier function. Default: (none)
    "ignorehost": true,
    "connTimeout": 10000, // integer - How long (in milliseconds) to wait for the SSH handshake to complete. Default: 10000
    "keepalive": 10000 // integer - How often (in milliseconds) to send SSH-level keepalive packets to the server (in a similar way as OpenSSH's ServerAliveInterval config option). Set to 0 to disable. Default: 10000
}

FTP & FTPS Configuration Options

{
    "protocol": "ftp",
    "host": "example.com", // string - The hostname or IP address of the FTP server. Default: 'localhost'
    "port": 21, // integer - The port of the FTP server. Default: 21
    "user": "user", // string - Username for authentication. Default: 'anonymous'
    "pass": "pass", // string - Password for authentication. Default: 'anonymous@'
    "remote": "/",
    "secure": false, // mixed - Set to true for both control and data connection encryption, 'control' for control connection encryption only, or 'implicit' for implicitly encrypted control connection (this mode is deprecated in modern times, but usually uses port 990) Default: false
    "secureOptions": null, // object - Additional options to be passed to tls.connect(). Default: (null) see http://nodejs.org/api/tls.html#tls_tls_connect_options_callback
    "connTimeout": 10000, // integer - How long (in milliseconds) to wait for the control connection to be established. Default: 10000
    "pasvTimeout": 10000, // integer - How long (in milliseconds) to wait for a PASV data connection to be established. Default: 10000
    "keepalive": 10000 // integer - How often (in milliseconds) to send a 'dummy' (NOOP) command to keep the connection alive. Default: 10000
}

hatzopoulos avatar Feb 28 '15 02:02 hatzopoulos

privatekey should probably note that the string should be a file path to the private key... I know it should have been my first choice, but I encoded the private key file with \n and put that in... it was after I determined that it really is supposed to be a path.

tracker1 avatar Aug 13 '15 10:08 tracker1

The README says

Buffer or string that contains a private key for either key-based or hostbased user authentication (OpenSSH format)

It should have worked if you had left out the \ns or escaped them properly

jpxd avatar Aug 13 '15 11:08 jpxd

But Wiki > Settings says:

key: set privatekey to the path to your private key, set passphrase if key is encrypted

wasikuss avatar Aug 13 '15 11:08 wasikuss

Funny... We use the mscdex/ssh2 module for SFTP. The keyparser used there expects a buffer or a string in the OpenSSH format BUT: We seem to support both path and key if I understand this line correctly: https://github.com/mgrenier/remote-ftp/blob/96bfd7d9a46d7b2b15ac32362c129c78c0b57a2e/lib/client.js#L170

jpxd avatar Aug 13 '15 12:08 jpxd

@jpxd no, line means that if privatekey is set then read file that it targets to. so remote-ftp supports only path

wasikuss avatar Aug 13 '15 12:08 wasikuss

Ah you`re right. I'll update it in the README

jpxd avatar Aug 13 '15 13:08 jpxd