mac 终端配置

下载iTerm

1 配置别名

  • 配置
$ vim ~/.bash_profile

加入内容:

alias "jump=ssh 'lynn.tian@jump1.ucloudadmin.com'"
  • 初始化
$ ~/.zshrc

加入内容:

最后一行加入

source ~/.bash_profile

2 多窗口免密登陆

多窗口时,只需要登录一次即可。

$ vim ~/.ssh/config

加入内容:

host *
ControlMaster auto
ControlPath ~/.ssh/master-%r@%h:%p

3 ssh设置别名

如果没有创建文件~/.ssh/config

vim ~/.ssh/config

添加内容

Host node-config
HostName 172.18.38.88
User root
posted @ 2021-05-26 08:22  tianzhh_lynn  阅读(68)  评论(0编辑  收藏  举报