VsCode免密登录

创建本地密匙

按下Win+R输入cmd,输入

bash 复制代码
ssh-keygen -t rsa

然后连续回车直到结束

找到Your public key has been saved in C:\Users\Administrator/.ssh/id_rsa.pub,每个人都不一样找到密匙所在地

打开id_rsa.pub这个文件,可以用记事本打开,复制内容

创建服务器密匙

同上,在服务器的命令行窗口输入

bash 复制代码
ssh-keygen -t rsa

找到Your public key has been saved in /root/.ssh/id_rsa.pub

bash 复制代码
cd /root/.ssh
vim authorized_keys
# 将上面本地主机的密匙复制进来, wq 保存

结束!over

相关推荐
lusklusklusk4 小时前
使用Visual Studio一步步创建并部署SSRS_PBIRS报表:数据源配置、图表设计、参数化查询、部署参数与排错实战
数据库·ide·visual studio
解道Jdon13 小时前
Rust重写OpenCode Rune:性能提升最高100倍
ide·windows·git·svn·eclipse·github·visual studio
莫卢俊德13 小时前
vscode ssh config
ide·vscode·ssh
郝学胜-神的一滴2 天前
Effective Python 条款44:善用属性注解
开发语言·c++·vscode·python·算法·stl
BD_Marathon5 天前
安装Jupyter notebook
ide·python·jupyter
讓丄帝愛伱6 天前
Zed Markdown 预览不能铺满全屏的原因及解决
ide
FungLeo7 天前
FengCMS · PHP+MySQL 升级实录 · 编辑器迁移:KindEditor → wangEditor5 +服务端 HTML Purifier
mysql·编辑器·php·富文本编辑器·fengcms
BD_Marathon7 天前
Jupyter魔法命令
ide·python·jupyter
郝学胜-神的一滴7 天前
Effective STL 条款 07:指针容器销毁前先删除
开发语言·c++·vscode·leetcode·rpc·visual studio
aaaameliaaa8 天前
VSCode的安装与配置
ide·笔记·vscode·编辑器