惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

K
Kaspersky official blog
Martin Fowler
Martin Fowler
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
V
Visual Studio Blog
博客园_首页
Engineering at Meta
Engineering at Meta
The Cloudflare Blog
MongoDB | Blog
MongoDB | Blog
Blog — PlanetScale
Blog — PlanetScale
T
The Blog of Author Tim Ferriss
雷峰网
雷峰网
D
Docker
博客园 - 司徒正美
S
SegmentFault 最新的问题
M
MIT News - Artificial intelligence
博客园 - 叶小钗
博客园 - 三生石上(FineUI控件)
U
Unit 42
J
Java Code Geeks
A
About on SuperTechFans
N
Netflix TechBlog - Medium
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
S
Security Affairs
I
Intezer
Cisco Talos Blog
Cisco Talos Blog
C
Cyber Attacks, Cyber Crime and Cyber Security
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
B
Blog RSS Feed
P
Privacy & Cybersecurity Law Blog
T
Tenable Blog
T
Threatpost
H
Hacker News: Front Page
G
Google Developers Blog
博客园 - 【当耐特】
Hugging Face - Blog
Hugging Face - Blog
Apple Machine Learning Research
Apple Machine Learning Research
L
Lohrmann on Cybersecurity
大猫的无限游戏
大猫的无限游戏
Google DeepMind News
Google DeepMind News
A
Arctic Wolf
S
Secure Thoughts
GbyAI
GbyAI
NISL@THU
NISL@THU
S
Security @ Cisco Blogs
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
Webroot Blog
Webroot Blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
O
OpenAI News
Spread Privacy
Spread Privacy
Application and Cybersecurity Blog
Application and Cybersecurity Blog

博客园 - NewSea

Linux 安装IntelAx211无线网卡 解决 K8sApi 部署后报 Unknown apiVersionKind apps/v1/Deployment is it registered? Docker 启动前后端脚本 docker 一键启动 mariadb 分区脚本 Spring笔记--@ConditionalOnBean坑 K8s笔记 ubuntu18+k8s单机版+kuboard+harbor安装笔记 yapi 自定义Json的数据类型 Nginx笔记 k3s+rancher+harbor 笔记 postgresql 笔记 vscode 笔记 发布Jar包到中央仓库 Java开发笔记汇总 - NewSea - 博客园 css 适配 nui-app 笔记 Java里的不能与无用. Swagger 配置
SSH 配置
NewSea · 2019-01-03 · via 博客园 - NewSea

用途

  • ssh , scp 不用密码
  • git 不用密码

方式

https://www.cnblogs.com/horanly/p/6604104.html
https://www.putty.org/

ed25519 性能更好,比 rsa 短很多。

ssh-keygen -t ed25519 -C "youremail@example.com"  -f dc-ed25519

id_rsa.pub -> gitlab ssh key

如果 pub Copy到另一台电脑, 一定要重新设置权限:

sudo chmod 600 id_rsa

sudo chmod 777 known_hosts

其它生成工具: http://www.cnblogs.com/pixy/p/4722381.html

配置多个 密钥:https://blog.csdn.net/dbb_zifeng/article/details/71698865

添加到 agent:

ssh-agent bash
ssh-add 13466496863
ssh-add iamudi

本地私钥配置文件

把私钥放到本地 .ssh 文件夹下。
配置文件很重要: 本地文件名: config 无后缀名. 在.ssh 文件下.

Host gitee2.com
    HostName gitee.com
    IdentityFile ~/.ssh/iamudi
    User iamudi@163.com

Host gitee.com
    HostName gitee.com
    Port 22
    IdentityFile ~/.ssh/13466396863
    User 13466396863@163.com

公钥服务器位置

/root/.ssh/authorized_keys

如果有多个客户端, 在 文件中追加.pub 公钥 即可.

cat /root/.ssh/id_rsa.pub >> authorized_keys

使用

这样在使用的时候:

git clone git@gitee2.com:iamudi/inv.git
ssh root@lzh

可以使用别名了.