gmacario / my-agl-pipelines

Jenkins Pipelines for building the AGL Distribution
MIT License
2 stars 1 forks source link

ERROR: Error fetching remote repo 'origin' #14

Closed gmacario closed 7 years ago

gmacario commented 7 years ago

Pipeline triggered with default parameters:

Excerpt from http://build-gmhome.solarma.it:9080/job/gmacario/job/my-agl-pipelines/job/master/4/console

Started by user Admin (build-gmhome)
Connecting to https://api.github.com using admin/****** (Github Access Token)
Obtained Jenkinsfile from 9cdbc6988f1ae817b02998595a2bd72bd1bc0e63
[Pipeline] properties
[Pipeline] node
Running on master in /var/jenkins_home/workspace/rio_my-agl-pipelines_master-HJGJMZV5UCL34DNFVMHQ2GSW5EC76ZPK5ZTKIAHH7EMTO7N47IOQ
[Pipeline] {
[Pipeline] stage
[Pipeline] { (Declarative: Checkout SCM)
[Pipeline] checkout
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from 2 remote Git repositories
 > git config remote.origin.url https://github.com/gmacario/my-agl-pipelines.git # timeout=10
Fetching upstream changes from https://github.com/gmacario/my-agl-pipelines.git
 > git --version # timeout=10
using GIT_ASKPASS to set credentials Github Access Token
 > git fetch --tags --progress https://github.com/gmacario/my-agl-pipelines.git +refs/heads/*:refs/remotes/origin/*
 > git config remote.origin1.url https://github.com/gmacario/my-agl-pipelines.git # timeout=10
Fetching upstream changes from https://github.com/gmacario/my-agl-pipelines.git
using GIT_ASKPASS to set credentials Github Access Token
 > git fetch --tags --progress https://github.com/gmacario/my-agl-pipelines.git +refs/pull/*/head:refs/remotes/origin/pr/*
Checking out Revision 9cdbc6988f1ae817b02998595a2bd72bd1bc0e63 (master)
 > git config core.sparsecheckout # timeout=10
 > git checkout -f 9cdbc6988f1ae817b02998595a2bd72bd1bc0e63
 > git rev-list 9cdbc6988f1ae817b02998595a2bd72bd1bc0e63 # timeout=10
[Pipeline] }
[Pipeline] // stage
[Pipeline] stage
[Pipeline] { (Declarative: Agent Setup)
[Pipeline] sh
[rio_my-agl-pipelines_master-HJGJMZV5UCL34DNFVMHQ2GSW5EC76ZPK5ZTKIAHH7EMTO7N47IOQ] Running shell script
+ docker pull gmacario/build-yocto:latest
latest: Pulling from gmacario/build-yocto
Digest: sha256:6326f7f69518c182a777b4601049b7a759e7667e40dffd488dbe8a6861896250
Status: Image is up to date for gmacario/build-yocto:latest
[Pipeline] }
[Pipeline] // stage
[Pipeline] sh
[rio_my-agl-pipelines_master-HJGJMZV5UCL34DNFVMHQ2GSW5EC76ZPK5ZTKIAHH7EMTO7N47IOQ] Running shell script
+ docker inspect -f . gmacario/build-yocto:latest
.
[Pipeline] withDockerContainer
$ docker run -t -d -u 1000:1000 -w /var/jenkins_home/workspace/rio_my-agl-pipelines_master-HJGJMZV5UCL34DNFVMHQ2GSW5EC76ZPK5ZTKIAHH7EMTO7N47IOQ --volumes-from 4e04af57bd9d8e133ba5ba9fe4e81c4c0e6659084ea99851403be1568f84b166 -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** --entrypoint cat gmacario/build-yocto:latest
[Pipeline] {
[Pipeline] stage
[Pipeline] { (Checkout)
[Pipeline] echo
Checkout stage
[Pipeline] git
 > git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
 > git config remote.origin.url "${params.gitUrl}" # timeout=10
Fetching upstream changes from "${params.gitUrl}"
 > git --version # timeout=10
 > git fetch --tags --progress "${params.gitUrl}" +refs/heads/*:refs/remotes/origin/*
ERROR: Error fetching remote repo 'origin'
hudson.plugins.git.GitException: Failed to fetch from "${params.gitUrl}"
    at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:809)
    at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1076)
    at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1107)
    at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:109)
    at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:83)
    at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:73)
    at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
    at hudson.security.ACL.impersonate(ACL.java:260)
    at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)
Caused by: hudson.plugins.git.GitException: Command "git fetch --tags --progress "${params.gitUrl}" +refs/heads/*:refs/remotes/origin/*" returned status code 128:
stdout: 
stderr: fatal: '"${params.gitUrl}"' does not appear to be a git repository
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:1866)
    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1585)
    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$300(CliGitAPIImpl.java:71)
    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:348)
    at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:807)
    ... 13 more
[Pipeline] }
[Pipeline] // stage
[Pipeline] stage
[Pipeline] { (Build)
Stage 'Build' skipped due to earlier failure(s)
[Pipeline] }
[Pipeline] // stage
[Pipeline] stage
[Pipeline] { (Test)
Stage 'Test' skipped due to earlier failure(s)
[Pipeline] }
[Pipeline] // stage
[Pipeline] stage
[Pipeline] { (Deploy)
Stage 'Deploy' skipped due to earlier failure(s)
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
$ docker stop --time=1 d5e6f133b6e7d7102fc23e20ec54fd57e980cd06ee45c603df4e23d77e633a02
$ docker rm -f d5e6f133b6e7d7102fc23e20ec54fd57e980cd06ee45c603df4e23d77e633a02
[Pipeline] // withDockerContainer
[Pipeline] }
[Pipeline] // node
[Pipeline] End of Pipeline

GitHub has been notified of this commit’s build result

ERROR: null
Finished: FAILURE
gmacario commented 7 years ago

Reproduced issue on http://ies-genbld01-ub16.ies.mentorg.com:9080/

It looks like the first execution of the pipeline from inside a clean workspace is successful, while the second results in the error above. Compare