56 lines
1.6 KiB
Plaintext
56 lines
1.6 KiB
Plaintext
|
pipeline {
|
||
|
agent any
|
||
|
|
||
|
parameters {
|
||
|
buildSelector(
|
||
|
defaultSelector: lastSuccessful(),
|
||
|
description: 'Which build to use for copying artifacts',
|
||
|
name: 'BUILD_SELECTOR'
|
||
|
)
|
||
|
|
||
|
buildSelector(
|
||
|
defaultSelector: lastSuccessful(),
|
||
|
description: 'Which build to use for copying artifacts',
|
||
|
name: 'BUILD_SELECTOR_DATASET'
|
||
|
)
|
||
|
|
||
|
buildSelector(
|
||
|
defaultSelector: lastSuccessful(),
|
||
|
description: 'Which build to use for copying artifacts',
|
||
|
name: 'BUILD_SELECTOR_TRAINING'
|
||
|
)
|
||
|
}
|
||
|
|
||
|
|
||
|
stage('copy artifacts')
|
||
|
{
|
||
|
steps
|
||
|
{
|
||
|
copyArtifacts(fingerprintArtifacts: true, projectName: 's434742-create-dataset', selector: buildParameter('WHICH_BUILD_DATASET'))
|
||
|
copyArtifacts(fingerprintArtifacts: true, projectName: 's434742-training', selector: buildParameter('WHICH_BUILD_TRAINING'))
|
||
|
}
|
||
|
}
|
||
|
|
||
|
stage('docker-training') {
|
||
|
steps {
|
||
|
script {
|
||
|
def img = docker.build('patlaz/ium:1.0')
|
||
|
img.inside {
|
||
|
sh 'chmod +x avocado-evaluation.py'
|
||
|
sh 'python3 avocado-evaluation.py'
|
||
|
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
|
||
|
stage('sendMail') {
|
||
|
steps{
|
||
|
emailext body: currentBuild.result ?: 'SUCCESS',
|
||
|
subject: 's434742 evaluation',
|
||
|
to: '26ab8f35.uam.onmicrosoft.com@emea.teams.ms'
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|