配置VS Code的远程调试环境 remote-ssh
安装Vscode
安装插件Remote - SSH
https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-ssh
配置远程访问
添加Windows本地的key到远程linux
# windows下生成key
ssh-keygen -t rsa -C "your_email@example.com"
# git bash上传 id_rsa.pub 到 远程linux
ssh-copy-id -i ~/.ssh/id_rsa.pub username@x.x.x.x
修改windows本地的ssh配置
C:\Users\myUser.ssh\config
Host my_linux_name
HostName 192.168.2.5
Port 22
User root