jenkins源码管理,添加SSH地址后报错:

  Could not read from remote repository.

  Please make sure you have the correct access rights and the repository exists.

有的在使用SSH地址,在jenkins上拉取Gitlab上的项目,可能会报错:

这是刚添加完gitlab地址,就报的错。

也有可能此时没有报错,但是在进行jenkins构建的时候,报错:

Started by GitLab push by AngelSXD
Started by GitLab push by AngelSXD
Building in workspace /var/jenkins_home/workspace/swapping
using credential 798371b9-6a3d-44bf-b752-713db6a9920a
Cloning the remote Git repository
Cloning repository git@192.168.92.130:8090/root/swapping.git
> /usr/bin/git init /var/jenkins_home/workspace/swapping # timeout=10
Fetching upstream changes from git@192.168.92.130:8090/root/swapping.git
> /usr/bin/git --version # timeout=10
using GIT_SSH to set credentials
> /usr/bin/git fetch --tags --progress git@192.168.92.130:8090/root/swapping.git +refs/heads/*:refs/remotes/origin/*
ERROR: Timeout after 10 minutes
ERROR: Error cloning remote repo 'origin'
hudson.plugins.git.GitException: Command "/usr/bin/git fetch --tags --progress git@192.168.92.130:8090/root/swapping.git +refs/heads/*:refs/remotes/origin/*" returned status code 128:
stdout:
stderr: Terminated
fatal: Could not read from remote repository. Please make sure you have the correct access rights
and the repository exists. at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2042)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1761)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$400(CliGitAPIImpl.java:72)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:442)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$2.execute(CliGitAPIImpl.java:655)
at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1152)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1192)
at hudson.scm.SCM.checkout(SCM.java:504)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1208)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:574)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:499)
at hudson.model.Run.execute(Run.java:1810)
at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:543)
at hudson.model.ResourceController.execute(ResourceController.java:97)
at hudson.model.Executor.run(Executor.java:429)
ERROR: Error cloning remote repo 'origin'
Finished: FAILURE

解决方法:

1.gitlab上拉取地址正确无误

2.各个必要的插件都安装成功

在确保了上面两点都无误的情况下,可以改用Http地址去clone项目!!!!!!!

【Devops】【docker】【CI/CD】jenkins源码管理,添加SSH地址后报错+Jenkins构建报错:Please make sure you have the correct access rights and the repository exists.的更多相关文章

  1. 【Devops】【docker】【CI/CD】Jenkins源码管理,设置gitlab上项目的clone地址 + jenkins构建报错:Please make sure you have the correct access rights and the repository exists.

    注意,如果 jenkins构建报错:Please make sure you have the correct access rights and the repository exists. 而此时 ...

  2. jenkins源码管理git分支参数化

    多个分支来回切换构建时,每次都需要去很多个job里面改分支名称,比较费时,分支参数化后可以只改一处就ok啦 步骤: 1.进入系统管理--系统设置 2.勾选全局变量,然后输入分支变量名和对应的分支名称 ...

  3. Docker:pipeline编写基本技巧- jenkins配置通过免交互方式拉取git源码管理仓库的代码

    工作中,从git仓库拉取代码有2种方式:交互式和非交互式 什么是交互式?就是拉取需要权限才能访问的代码时,需要输入密码 免交互式呢? 是通过密钥,私钥的方式,让服务端信任客户端,产生信任后,任何一次客 ...

  4. 【Devops】【docker】【CI/CD】Jenkins自动安装JDK需要提供Oracle的账号密码,否则报错:Unable ro auto-install JDK until the license is accepted

    Jenkins自动安装JDK需要提供Oracle的账号密码,否则报错:Unable ro auto-install JDK  until the  license is accepted 解决方法: ...

  5. Jenkins新建项目中源码管理Repository URL使用Git报错:Failed to connect to repository : Command "git ls-remote -h......

    之前部署了Gitlab+Gerrit+Jenkins持续集成环境,但在Jenkins中新建项目的源码管理"Repository URL"中添加git地址环节出现了问题,信息为&qu ...

  6. jenkins配置源码管理git

    一.首先安装上来jenkins 二.下载安装jenkins的git插件:Git plugin 三.新建一个jenkins项目,选择构建一个自由风格的软件项目: 源码管理选择git,Repository ...

  7. jenkins持续集成源码管理选项为None,构建失败找不到git.exe解决办法

    我的jenkins版本为Jenkins ver. 2.19.1 1.源码管理选项只有None的解决办法: 在插件管理中心,搜索对应的源码管理插件这里以git为例,搜索git plugin点击右下角的安 ...

  8. 【Linux】Jenkins+Git源码管理(三)

    摘要 本章介绍Jenkins配合Git源码管理,关于Jenkins的基本操作,参照[Linux]Jenkins配置和使用(二) 事例说明:在linux环境下,安装的jenkins,已安装git. 代码 ...

  9. CI Weekly #6 | 再谈 Docker / CI / CD 实践经验

    CI Weekly 围绕『 软件工程效率提升』 进行一系列技术内容分享,包括国内外持续集成.持续交付,持续部署.自动化测试. DevOps 等实践教程.工具与资源,以及一些工程师文化相关的程序员 Ti ...

随机推荐

  1. 360加固保的dex脱壳方法

    完全测试了看雪论坛的方法,发现并没有脱壳,依然无法反编译 http://bbs.pediy.com/thread-213377.htm 使用上面方法的结果是会得到16个dex文件,只有一个是与程序相关 ...

  2. 浅谈js设计模式之发布 — 订阅模式

    发布 — 订阅模式又叫观察者模式,它定义对象间的一种一对多的依赖关系,当一个对象的状态发生改变时,所有依赖于它的对象都将得到通知.在 JavaScript开发中,我们一般用事件模型来替代传统的发布 — ...

  3. 【LOJ】#2118. 「HEOI2015」兔子与樱花

    题解 怎么觉得都像树dp,不像贪心 但是树dp确实做不了 把每个节点的值设置为樱花+儿子数 把儿子合并到父亲上就是父亲的剩余容量加上儿子的值-1 每次在父亲的时候将儿子的值排序然后能加就加上 因为儿子 ...

  4. bzoj 1178 [Apio2009]CONVENTION会议中心

    这题好难啊! 我好菜啊! 思路:对于最多线段不相交, 我们可以按左端点sort之后,贪心取. 但是这个题要求选取的线段排序之后序号的字典序最小. 那么我们如果按序号贪心地从大往小往里放, 那么对于第k ...

  5. es6 Promise 事件机制分析

    最近在学习es6的Promise,其中涉及到了Promsie的事件执行机制,因此总结了关于Promise的执行机制,若有错误,欢迎纠错和讨论. 在阮一峰老师的书中<es6 标准入门>对Pr ...

  6. oracle批量插入優化方案

    今天聽DBA説如果從一個表批量查詢出一批數據之後批量插入另外一張表的優化方案: 1)不寫歸檔日誌: 2)採用獨佔 關於insert /*+ append */我們需要注意以下三點: a.非歸檔模式下, ...

  7. Linux驱动之混杂设备(misc)

    字符设备之混杂设备: 定义混杂设备: struct misdevice{ int minor; //为什么这里只有次设备号,因为混杂设备是一种在 /////////////////////////Li ...

  8. 7617:输出前k大的数

    7617:输出前k大的数 查看 提交 统计 提问 总时间限制: 10000ms 单个测试点时间限制: 1000ms 内存限制: 65536kB 描述 给定一个数组,统计前k大的数并且把这k个数从大到小 ...

  9. [CEOI2017]Palindromic Partitions

    [CEOI2017]Palindromic Partitions 题目大意: 给出一个长度为\(n(n\le10^6)\)的只包含小写字母字符串,要求你将它划分成尽可能多的小块,使得这些小块构成回文串 ...

  10. linux_远程copy

    1:远程copy [linux对linux 远程拷贝]   scp 文件名 root@远程ip:/路径/   将本地home目录下的test.tar的文件拷贝到远程主机192.168.1.23的/ho ...