Sublime sftp connects to wrong container

寵の児 提交于 2020-01-25 04:05:12

问题


I have two different Docker containers under the same host stack.

Currently I'm on OSX and using Sublime Text 3 with the SFTP plugin.

For each different dev environment (Docker container) I have a different sftp-config.jsonfile and I am using different SSH key files.

Here are my host entries for both files:

first host:

"host": "example-dev.xxx.de", "user": "userxxx", "remote_path": "/home/xxx/www_trunk", "ssh_key_file": "~/work/Misc/pass/private1.pem"

second host:

"host": "example2-dev.xxx.de", "user": "userxxx", "remote_path": "/home/xxx/www_trunk", "ssh_key_file": "~/work/Misc/pass/private2.pem"

But when I try to connect to the second host, I always end up on the fist one.

I had the same problem with the OSX terminal before, until I added "IdentitiesOnly YES" to the SSH config file, then I connected to the correct dev environment.

Is there any setting similar to "IdentitiesOnly YES" that I need to add to the sftp-config.json files, so that my sublime text also connects to the correct dev environment?

来源:https://stackoverflow.com/questions/36340195/sublime-sftp-connects-to-wrong-container

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!