時間:2015-1-30
Problem
repo init -u [email protected]:manifest.git -m cdos_rawos.xml
Get [email protected]:repo.git
Permission denied, please try again.
Permission denied, please try again.
Permission denied (publickey,password).
原因
ssh沒有配置好
解決方法-檢查權限
ssh -v [email protected]
在terminal中,把root下的~/.ssh文件夾中的公鑰和私鑰都複製到jenkins文件夾下.ssh文件夾中。(jenkins文件夾的權限是用戶jenkins,所以在terminal中檢查某一句語句是否可行的話,要先切換到jenkins用戶中(sudo su jenkins)),把複製的公鑰和私鑰的權限改成jenkins後,jenkins才能採用。
The problem was that somehow I created the ssh files with the root user. So the files owner was root.
The solution was just change the ownership to the jenkins user.
chown jenkins id_rsa.pub
chown jenkins id_rsa