Can't connect VS Code to Linux machine for remote development

此生再无相见时 提交于 2020-06-11 01:11:25

问题


I am getting this error on VS Code and have no clue why it fails

[15:14:59.543] Log Level: 2
[15:14:59.555] remote-ssh@0.51.0
[15:14:59.555] win32 x64
[15:14:59.560] SSH Resolver called for "ssh-remote+xx.xx.xx.xx", attempt 1
[15:14:59.561] SSH Resolver called for host: xx.xx.xx.xx
[15:14:59.561] Setting up SSH remote "xx.xx.xx.xx"
[15:14:59.621] Using commit id "0ba0ca52957102ca3527cf479571617f0de6ed50" and quality "stable" for server
[15:14:59.624] Install and start server if needed
[15:15:01.964] getPlatformForHost was canceled
[15:15:01.965] Resolver error: Connecting was canceled
[15:15:01.973] ------

回答1:


In dialog box where you have typed user@host type/select Linux/Windows/etc. depends what you are using, then type/select Continue, then type password for remote session.




回答2:


Add one key in your settings.json as below. Plase remember to replace the $remote_server_name to yours.

    "remote.SSH.remotePlatform": {
        "$remote_server_name": "linux"
    }

Menu:File->Perference->Settings click to open settings.json



来源:https://stackoverflow.com/questions/60974357/cant-connect-vs-code-to-linux-machine-for-remote-development

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