1
votes

I am running a an automation script in Jenkins . Does 'Archive artifacts only if build is successful' set as true means, any artifacts won't be created in Jenkins if build fails ? OR does this means the artifacts are created in the specified folder,but they are not saved for later and once delete workspace is run,the artifacts created will be gone forever.

1

1 Answers

0
votes

Archiving artifacts in jenkins means that the artifacts will be saved on the Jenkins master (for later usage). Even if the job is finished and the workspace is cleaned. For example for maven this setting means: if your maven build is successful (no failures) then the created artifacts (jars, wars or an ear) will be archived/stored on the Jenkins master and you can safely clean the workspace.

I don't know mortar but in your case this will probably also mean: if the build is successful on your Jenkins slave, then your Artifacts will be copied to the jenkins master and stored there. If you clean your workspace after the build or just not isn't related.