pipeline { agent { docker { image 's444507_create_dataset_image' } } parameters { buildSelector(defaultSelector: lastSuccessful(), description: 'Which build to use for copying artifacts.', name: 'BUILD_SELECTOR') gitParameter branchFilter: 'origin/(.*)', defaultValue: 'master', name: 'BRANCH', type: 'PT_BRANCH' } stages { stage('Get arifacts') { steps { copyArtifacts filter:'*', projectName: 's444507-create-dataset', selector: buildParameter('BUILD_SELECTOR') copyArtifacts filter:'*', projectName: '444507-training/${BRANCH}', selector: buildParameter('BUILD_SELECTOR'), optional: true copyArtifacts filter:'*', projectName: 's444507-evaluation/master', selector: buildParameter('BUILD_SELECTOR'), optional: true } } stage('Run evaluation') { steps { sh "python3 ./lab06_evaluation.py ${currentBuild.number}" } } } post { success { archiveArtifacts artifacts: 'metrics.*', followSymlinks: false } always { emailext body: "${currentBuild.currentResult}", subject: 's444507-evaluation', to: 'e19191c5.uam.onmicrosoft.com@emea.teams.ms' } } }