0
votes

How can I upload files to an Artifactory by Jenkins Artifactory Plugin in the middle of the build? After uploading, the job will trigger another job which will download the artifact from the Artifactory. Arching artifacts in the Jenkins jobs is not an option for me because we should keep artifacts in Artifactory.

I could use curl to upload to the Artifactory, but I need to have old builds discarding (by Jenkins Artifactory Plugin). I could use "Generic-Artifactory Integration" in the jobs configuration, but it uploads only at the end of the job build.

1
Not sure I totally understand the use case. Can you please elaborate a bit? Why does it matters if the files are uploaded at the end of the build if this build trigger another file to download them? Usually the trigger happens at the and of the buildAriel
You can integrate artifactory with maven , and use a maven build to deploy custom files to artifactory followed by "A trigger other builds with parameterized plugin"prudviraj

1 Answers

0
votes

We have used the jfrog cli to do this on generic jobs. Be sure to include the —build-name and —build-number options to have your artifacts collected correctly when the Artifactory plugin publishes the build info.