[解决][jenkins]Gerritrepo 远程调用被阻止
Problemrepo init -u git@192.168.162.142:manifest.git -m cdos_rawos.xmlGet git@192.168.162.142:repo.gitPermission denied, please try again.Permission denied, please try again.Permission denied
·
作者:disappearedgod
时间:2015-1-30
Problem
repo init -u git@192.168.162.142:manifest.git -m cdos_rawos.xml
Get git@192.168.162.142:repo.git
Permission denied, please try again.
Permission denied, please try again.
Permission denied (publickey,password).
原因
ssh没有配置好
解决方法-检查权限
ssh -v git@192.168.162.142
在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
chown jenkins id_rsa.pub
chown jenkins id_rsa
repo同步需要一个xml脚本,在Gerrit Repo -> Advance -> Mainifest File中设置 (*.xml)
开放原子开发者工作坊旨在鼓励更多人参与开源活动,与志同道合的开发者们相互交流开发经验、分享开发心得、获取前沿技术趋势。工作坊有多种形式的开发者活动,如meetup、训练营等,主打技术交流,干货满满,真诚地邀请各位开发者共同参与!
更多推荐
已为社区贡献1条内容
所有评论(0)