使用git拉取代码时报错
fatal: cannot run ssh: No such file or directory
fatal: unable to fork
解决办法:
- 打开如下文件
vim /etc/profile
-
添加如下代码,添加git环境变量
export GIT_SSH=/usr/bin/ssh
- 执行如下代码,使配置生效
source /etc/profile
生效 ok
fatal: cannot run ssh: No such file or directory
fatal: unable to fork
vim /etc/profile
添加如下代码,添加git环境变量
export GIT_SSH=/usr/bin/ssh
source /etc/profile
生效 ok