Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-21110

Git Publisher fails because remote.origin.url is not set

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • git-plugin
    • None
    • Jenkins ver. 1.544
      Jenkins GIT plugin ver. 2.0
      Jenkins GIT client plugin ver. 1.6.0

      I saw a comment that may be the basis of the problem:

      git-plugin 2.0 don't use remote.<foo>.url anymore

      The error is very similar to JENKINS-20258 but this is occurring in the Git Publisher Post-build Actions:

      07:23:10 Started by an SCM change
      07:23:10 Building on master in workspace XXX
      07:23:10 Fetching changes from the remote Git repository
      07:23:10 Fetching upstream changes from ssh://XXX.git
      07:23:20 Checking out Revision XXX (origin/perl-tests)
      07:23:23 Cleaning workspace
      07:23:23 Resetting working tree
      07:23:24 Triggering XXX
      07:59:13 XXX completed with result SUCCESS
      07:59:13 Pushing HEAD to branch XXX at repo origin
      07:59:14 ERROR: Failed to push branch XXX to origin
      07:59:14 hudson.plugins.git.GitException: Command "git config --get remote.origin.url" returned status code 1:
      07:59:14 stdout: 
      07:59:14 stderr: 
      07:59:14 	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1099)
      07:59:14 	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1076)
      07:59:14 	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:917)
      07:59:14 	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:927)
      07:59:14 	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.getRemoteUrl(CliGitAPIImpl.java:656)
      07:59:14 	at hudson.plugins.git.GitAPI.getRemoteUrl(GitAPI.java:61)
      07:59:14 	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.push(CliGitAPIImpl.java:1129)
      07:59:14 	at hudson.plugins.git.GitAPI.push(GitAPI.java:65)
      07:59:14 	at hudson.plugins.git.GitPublisher.perform(GitPublisher.java:303)
      07:59:14 	at hudson.plugins.git.GitPublisher$1.endBuild(GitPublisher.java:138)
      07:59:14 	at hudson.matrix.MatrixBuild$MatrixBuildExecution.post2(MatrixBuild.java:403)
      07:59:14 	at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:706)
      07:59:14 	at hudson.model.Run.execute(Run.java:1703)
      07:59:14 	at hudson.matrix.MatrixBuild.run(MatrixBuild.java:304)
      07:59:14 	at hudson.model.ResourceController.execute(ResourceController.java:88)
      07:59:14 	at hudson.model.Executor.run(Executor.java:231)
      07:59:14 	at hudson.model.OneOffExecutor.run(OneOffExecutor.java:43)
      07:59:14 Notifying upstream projects of job completion
      07:59:14 Finished: SUCCESS
      

            ndeloof Nicolas De Loof
            nnutter Nathan Nutter
            Votes:
            6 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated:
              Resolved: