update jenkinsfile_train-sacred, jenkinsfile_predict
Some checks failed
s444356-evaluation/pipeline/head This commit looks good
s444356-training/pipeline/head There was a failure building this commit

This commit is contained in:
Maciej Czajka 2022-05-11 20:31:48 +02:00
parent cfaaedf748
commit b16fce0beb
2 changed files with 20 additions and 1 deletions

View File

@ -5,6 +5,10 @@ pipeline {
} }
} }
parameters { parameters {
buildSelector(
defaultSelector: lastSuccessful(),
description: 'Which build to use for copying artifacts for predict',
name: 'BUILD_SELECTOR')
string( string(
defaultValue: 'input_example.json', defaultValue: 'input_example.json',
description: 'Input file name', description: 'Input file name',
@ -16,7 +20,7 @@ pipeline {
stages { stages {
stage('Script') { stage('Script') {
steps { steps {
copyArtifacts projectName: 's444409-training/main', selector: lastSuccessful() copyArtifacts projectName: 's444409-training/main', selector: buildParameter('BUILD_SELECTOR')
sh 'python3 ./predict.py $INPUT' sh 'python3 ./predict.py $INPUT'
} }
} }

View File

@ -23,7 +23,22 @@ pipeline {
archiveArtifacts artifacts: 'my_model/**' archiveArtifacts artifacts: 'my_model/**'
sh 'rm -r mlruns' sh 'rm -r mlruns'
sh 'rm -r my_model' sh 'rm -r my_model'
build job: 's444356-evaluation/master/'
} }
} }
} }
post {
success {
emailext body: 'SUCCESS', subject: 's444356-training', to: 'e19191c5.uam.onmicrosoft.com@emea.teams.ms'
}
failure {
emailext body: 'FAILURE', subject: 's444356-training', to: 'e19191c5.uam.onmicrosoft.com@emea.teams.ms'
}
unstable {
emailext body: 'UNSTABLE', subject: 's444356-training', to: 'e19191c5.uam.onmicrosoft.com@emea.teams.ms'
}
changed {
emailext body: 'CHANGED', subject: 's444356-training', to: 'e19191c5.uam.onmicrosoft.com@emea.teams.ms'
}
}
} }