sshfs-node icon indicating copy to clipboard operation
sshfs-node copied to clipboard

Documentation is OK - Problem with "path" option

Open harkor opened this issue 9 years ago • 0 comments

Hello,

I'm trying to use your module but I ave some problems...

On the README, you say : sshfs.mount(user, host, mountpoint, callback);

If I check the code : /lib/sshfs-node.coffee I see : sshfs.mount = (host, mountpoint, options, callback)

In the options I use user, port and path.

But when I execute "sshfs.mount", It doesn't work and on the "Error", I don't see my remote host path.

`var mountOptions = { user : 'MYUSER', port : MYPORT, path : '/MY/FOLDER/FROM/ROOT/' };

sshfs.mount('MYHOST', '/home/MYUSER/MY_LOCAL_DIRECTORY/', mountOptions, function(result){ console.log(result); });`

The result is { Error: Command failed: sshfs -o cache=yes -o StrictHostKeyChecking=no MYUSER@MYHOST:/ /home/MYUSER/MY_LOCAL_DIRECTORY/ read: Connection reset by peer

The "path" option is not written on the error.

If I execute myself sshfs I can connect on the remote directory.

sshfs -p MYPORT MYUSER@MYHOST:/MY/FOLDER/FROM/ROOT/ /home/MYUSER/MY_LOCAL_DIRECTORY/

harkor avatar Jan 23 '17 09:01 harkor