0

I'm trying to connect remotely to a Ubuntu 18.04 instance on AWS using remote-ftp 2.2.4 from my local machine running Windows 10.

I have my .ftpconfig file at D:\Webserver, and have entered that value into remote-ftp's settings.

My .pem file is at C:/myKey.pem

But when I try to connect I keep getting

Remote FTP: Could not read .ftpconfig file.

Error: EISDIR: illegal operation on a directory, read

Where am I going wrong? This is my .ftpconfig file.

{
    "protocol": "sftp",
    "host": "00.000.0.00",
    "port": 22,
    "user": "ubuntu",
    "pass": "",
    "promptForPass": false,
    "remote": "/",
    "local": "",
    "agent": "",
    "privatekey": "C:/myKey.pem",
    "passphrase": "",
    "hosthash": "",
    "ignorehost": true,
    "connTimeout": 10000,
    "keepalive": 10000,
    "keyboardInteractive": false,
    "keyboardInteractiveForPass": false,
    "remoteCommand": "",
    "remoteShell": "",
    "watch": [],
    "watchTimeout": 500
}
Norman
  • 6,159
  • 23
  • 88
  • 141

1 Answers1

0

There seem to be other posts out there talking about the same error

NPM stuck giving the same error EISDIR: Illegal operation on a directory, read at error (native)

If you have git installed on windows, you can use the sftp command that ships with git bash. To use it open the git bash shell and run below command:

sftp -i /path/to/pemfile.pem ec2-user@1.2.3.4

EDIT: The issue seems to be the privatekey property. This post mentions you need to escape the back slashes

Issue Connection to server using Remote-FTP atom package and Private Keys

Also below documentation mentions "Path to the private key file (in OpenSSH format).". Also Try /myKey.pem or /c/myKey.pem

http://github-atom-io-staging-herokuapp-com.global.ssl.fastly.net/packages/remote-ftp

Bernie Lenz
  • 1,967
  • 23
  • 45