-
Bug
-
Resolution: Fixed
-
Major
-
Jenkins version: 1.644
Git plugin: 2.4.1
Git-client plugin: 1.19.1
Credential plugin: 1.24
When generating a new tag repository, I'm getting an HTTP Error 401. I think the credentials are not being sent on the command.
If I do the same from shell, works properly
These are the logs:
> git tag -l TAG-39 # timeout=10
> git tag -a -f -m http://oclrh65c109.isbcloud.isban.corp:9080/jenkins/job/ReleaseLokiAll/39/ TAG-39 # timeout=10
Pushing tag TAG-39 to repo Toms
> git --version # timeout=10
using .gitcredentials to set credentials
> git config --local credential.username jenkins # timeout=10
> git config --local credential.helper store --file=/tmp/git5654596688481070714.credentials # timeout=10
Setting http proxy: 172.31.219.30:8080
> git -c core.askpass=true push http://grddesavlngd01.nngg.corp:8080/almis/toms.git TAG-39
> git config --local --remove-section credential # timeout=10
ERROR: Failed to push tag TAG-39 to Toms
hudson.plugins.git.GitException: Command "git -c core.askpass=true push http://grddesavlngd01.nngg.corp:8080/almis/toms.git TAG-39" returned status code 1:
stdout:
stderr: * About to connect() to proxy 180.16.242.103 port 8080 (#0)
- Trying 180.16.242.103... * Connected to 180.16.242.103 (180.16.242.103) port 8080 (#0)
> GET http://grddesavlngd01.nngg.corp:8080/almis/toms.git/info/refs?service=git-receive-pack HTTP/1.1
User-Agent: git/1.7.1
Host: grddesavlngd01.nngg.corp:8080
Accept: /
Proxy-Connection: Keep-Alive
Pragma: no-cache
< HTTP/1.1 401 Unauthorized
< Content-Type: text/html; charset=UTF-8
< Set-Cookie: lang=en-US; Path=/; Max-Age=2147483647
< Set-Cookie: i_like_gogits=21e2bb502c6bf8f1; Path=/; HttpOnly
< Set-Cookie: _csrf=_776vIsNeDpq8HOElCg21pjXyzU6MTQ1MzQ1NzkxNDgzNTM3MjM0Ng%3D%3D; Path=/
< WWW-Authenticate: Basic realm="."
< Date: Fri, 22 Jan 2016 10:18:34 GMT
< X-Cache: MISS from bvmnglappmd01
< Transfer-Encoding: chunked
< Via: 1.1 bvmnglappmd01 (squid/3.5.9)
< Connection: keep-alive
<
- Ignoring the response-body
- Expire cleared
- Connection #0 to host 180.16.242.103 left intact
- Issue another request to this URL: 'http://grddesavlngd01.nngg.corp:8080/almis/toms.git/info/refs?service=git-receive-pack'
- Re-using existing connection! (#0) with host 180.16.242.103
- Connected to 180.16.242.103 (180.16.242.103) port 8080 (#0)
- Server auth using Basic with user 'jenkins'
> GET http://grddesavlngd01.nngg.corp:8080/almis/toms.git/info/refs?service=git-receive-pack HTTP/1.1
Authorization: Basic amVua2luczpqZW5raW5zLjIwMTU=
User-Agent: git/1.7.1
Host: grddesavlngd01.nngg.corp:8080
Accept: /
Proxy-Connection: Keep-Alive
Pragma: no-cache
< HTTP/1.1 401 Unauthorized
< Content-Type: text/plain
< Set-Cookie: lang=en-US; Path=/; Max-Age=2147483647
< Set-Cookie: i_like_gogits=0571ac89753ff346; Path=/; HttpOnly
< Set-Cookie: _csrf=qJdvkeyRG57WN-F1aFwpuRF6tqw6MTQ1MzQ1NzkxNDg4NjkxMjIzNg%3D%3D; Path=/
< Date: Fri, 22 Jan 2016 10:18:35 GMT
< Content-Length: 13
< X-Cache: MISS from bvmnglappmd01
< Via: 1.1 bvmnglappmd01 (squid/3.5.9)
< Connection: keep-alive
- The requested URL returned error: 401
- Closing connection #0
- About to connect() to proxy 180.16.242.103 port 8080 (#0)
- Trying 180.16.242.103... * Connected to 180.16.242.103 (180.16.242.103) port 8080 (#0)
> GET http://grddesavlngd01.nngg.corp:8080/almis/toms.git/info/refs HTTP/1.1
User-Agent: git/1.7.1
Host: grddesavlngd01.nngg.corp:8080
Accept: /
Proxy-Connection: Keep-Alive
Pragma: no-cache
< HTTP/1.1 200 OK
< Accept-Ranges: bytes
< Cache-Control: no-cache, max-age=0, must-revalidate
< Content-Length: 295
< Content-Type: text/plain; charset=utf-8
< Expires: Fri, 01 Jan 1980 00:00:00 GMT
< Last-Modified: Fri, 22 Jan 2016 10:18:35 GMT
< Pragma: no-cache
< Set-Cookie: lang=en-US; Path=/; Max-Age=2147483647
< Set-Cookie: i_like_gogits=5ebf987a8afeb55c; Path=/; HttpOnly
< Set-Cookie: _csrf=uCARWJUF8TYXFcXcPTpWLdX0s_E6MTQ1MzQ1NzkxNTA5MTYyNzkwMQ%3D%3D; Path=/
< Date: Fri, 22 Jan 2016 10:18:35 GMT
< X-Cache: MISS from bvmnglappmd01
< Via: 1.1 bvmnglappmd01 (squid/3.5.9)
< Connection: keep-alive
<
- Connection #0 to host 180.16.242.103 left intact
- Re-using existing connection! (#0) with host 180.16.242.103
- Connected to 180.16.242.103 (180.16.242.103) port 8080 (#0)
> GET http://grddesavlngd01.nngg.corp:8080/almis/toms.git/HEAD HTTP/1.1
User-Agent: git/1.7.1
Host: grddesavlngd01.nngg.corp:8080
Accept: /
Proxy-Connection: Keep-Alive
Pragma: no-cache
- The requested URL returned error: 404 Not Found
- Expire cleared
- Closing connection #0
- About to connect() to proxy 180.16.242.103 port 8080 (#0)
- Trying 180.16.242.103... * Connected to 180.16.242.103 (180.16.242.103) port 8080 (#0)
> PROPFIND http://grddesavlngd01.nngg.corp:8080/almis/toms.git/ HTTP/1.1
User-Agent: git/1.7.1
Host: grddesavlngd01.nngg.corp:8080
Accept: /
Proxy-Connection: Keep-Alive
Depth: 0
Content-Type: text/xml
Content-Length: 182
Expect: 100-continue
- The requested URL returned error: 404 Not Found
- Expire cleared
- Closing connection #0
error: Cannot access URL http://grddesavlngd01.nngg.corp:8080/almis/toms.git/, return code 22
fatal: git-http-push failed
error: failed to push some refs to 'http://grddesavlngd01.nngg.corp:8080/almis/toms.git'
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:1693)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:1441)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.access$300(CliGitAPIImpl.java:62)
at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$8.execute(CliGitAPIImpl.java:1769)
at hudson.plugins.git.GitPublisher.perform(GitPublisher.java:306)
at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:782)
at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:723)
at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:1047)
at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:668)
at hudson.model.Run.execute(Run.java:1763)
at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:531)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:410)
Build step 'Git Publisher' marked build as failure