0
votes

When configuring the Artifactory Plugin for "Generic-Artifactory" integration, someone changed the artifact name without updating the Jenkins2 plan and the upload no longer worked. Unfortunately, the Jenkins build never failed or warned us.

  • Is there an option in the specs that I have yet to find that would allow it to fail the build in this case?

I'm sure there's an obvious answer here somewhere, but I'm missing it. I don't want to write a script that checks for the artifact and exits if it's not there, although it would work. I'm looking for the right way to do this.

https://www.jfrog.com/confluence/display/RTF/Using+File+Specs

{
"files": [
{
"pattern": "$WORKSPACE/foobar.jar", 
"target": "libs-release-local/com/mycompany/foo-1.1.jar"
}
]
}
1

1 Answers

3
votes

Your desired functionality is the fail-no-op flag, which will fail the build if no files were affected (uploaded/downloaded) during the process.

The fail-no-op flag is only available in pipeline jobs, both in declarative and scripted syntax.