我正在尝试为sublime text设置一个私有的rsa密钥来访问ftp,就像在filezilla中一样。到目前为止,插件stfp/ftp运行良好,但我不知道如何设置访问私有服务器的密钥。
下面是我的json文件的一个示例:
"type": "sftp",
"sync_down_on_open": true,
"sync_same_age": true,
"host": "example.com",
"user": "username",
"password": "password",
"port": "22",
"remote_path": "/example/path/",
//"file_permissions": "664",
//"dir_permissions": "775",
"connect_timeout": 30,
"ssh_key_file": "~/.ssh/id_rsa",所以问题是这个“ssh_key_file”片段:"~/.ssh/id_rsa“应该可以完成这项工作,但是我需要知道: 1.我应该把我拥有的文件(key.ppk)放在哪里,2.我需要其他东西才能让它工作吗?
提前感谢您的帮助。
发布于 2018-03-07 21:20:22
这实际上是可行的:
{
// The tab key will cycle through the settings when first created
// Visit http://wbond.net/sublime_packages/sftp/settings for help
// sftp, ftp or ftps
"type": "sftp",
"sync_down_on_open": true,
"sync_same_age": true,
"host": "111.111.111.11",
"user": "admin",
"password": "password",
"port": "22",
"remote_path": "/",
//"file_permissions": "664",
//"dir_permissions": "775",
//"extra_list_connections": 0,
"connect_timeout": 30,
//"keepalive": 120,
//"ftp_passive_mode": true,
//"ftp_obey_passive_host": false,
"ssh_key_file": "C:/Program Files/Sublime Text 3/mykey.ppk",
//"sftp_flags": ["-F", "/path/to/ssh_config"],
//"preserve_modification_times": false,
//"remote_time_offset_in_hours": 0,
//"remote_encoding": "utf-8",
//"remote_locale": "C",
//"allow_config_upload": false,
}发布于 2020-03-14 03:30:06
Sublime Text 3(3.2.2版)
最后成功地将.ppk文件移到了一个不带空格的路径中。
"ssh_key_file": "C:/Users/Me/mykey.ppk"https://stackoverflow.com/questions/48949254
复制相似问题