ium_487194/Jenkinsfile_evaluation

38 lines
1.0 KiB
Plaintext

pipeline {
agent any
parameters {
string(name: 'Build', defaultValue: '1', description: 'Build num')
}
stages {
stage('checkout: Check out from version control') {
steps {
checkout([$class: 'GitSCM', branches: [[name: '*/master']], extensions: [], userRemoteConfigs: [[credentialsId: 's487194', url: 'https://git.wmi.amu.edu.pl/s487194/ium_487194']]])
}
}
stage('Docker'){
steps {
script {
def dockerImage = docker.image('s487194/ium:lab5_7')
dockerImage.inside {
copyArtifacts filter: 'classificationn_model.pt', projectName: "s487194-training/$BRANCH_NAME", optional: false
sh "python3 evaluate.py -build ${params.Build}"
archiveArtifacts artifacts: 'predictions.txt, metrics.txt', onlyIfSuccessful: true
}
}
}
}
}
}