-
Bug
-
Resolution: Unresolved
-
Critical
-
None
-
- Jenkins 2.319.3
- Jfrog jenkins-artifactory-plugin 3.15.1 or 3.15.4
I have configured a Jenkins pipeline to upload generated artifacts to the jFrog artifactory. Since version 3.15.1 no artifact is deployed.
Jenkinsfile:
pipeline { agent none stages { stage('Archive') { agent any steps { script { def server = Artifactory.server 'artifactory' sh "touch artifact.tgz" sh 'git log --pretty=format:%s -1' def uploadSpec = """{ "files": [ { "pattern": "artifact.tgz", "target": "test-repo/test.org/TEST/1-SNAPSHOT/TEST-1-bug_testing-x64.tgz" } ] }""" def buildInfo = server.upload spec: uploadSpec buildInfo.retention maxBuilds: 10, maxDays: 14, deleteBuildArtifacts: true server.publishBuildInfo buildInfo } } } } }
Running this pipeline the following output is created:
[Pipeline] sh + touch artifact.tgz [Pipeline] sh + git log --pretty=format:%s -1 meta: Jenkinsfile with basic instructions [Pipeline] newBuildInfo [Pipeline] artifactoryUpload Executing command: /bin/sh -c git log --pretty=format:%s -1 Failed fetching git branch from git directory: /var/lib/jenkins/workspace/NICESW-3426_jenkins_integtration/.git [Pipeline] publishBuildInfo Executing command: /bin/sh -c git log --pretty=format:%s -1 Failed fetching git branch from git directory: /var/lib/jenkins/workspace/NICESW-3426_jenkins_integtration/.git Deploying build info... Build-info successfully deployed. Browse it in Artifactory under https://***.com/artifactory/webapp/builds/***%20::%20feature%20::%20NICESW-3426_jenkins_integtration/40 Sending request for build retention, deleting build artifacts, max number of builds to store: 10, min build date: Wed Jan 26 18:20:04 CET 2022.
With the artifactory plugin in version 3.14.2 I do not have this issue.
It is possible to run the command within the pipeline without any error.
Can anyone help me to resolve this problem? Any idea/suggestion?