ium_426206/Jenkinsfile_predict_registry
Jan Nowak 44840aecf2
All checks were successful
s426206-evaluation/pipeline/head This commit looks good
s426206-training/pipeline/head This commit looks good
Predict registry own model docker parametr.
2021-05-23 19:09:08 +02:00

33 lines
1.1 KiB
Plaintext

pipeline {
agent any
parameters {
buildSelector(
defaultSelector: lastSuccessful(),
description: 'Which build to use for copying artifacts for predict',
name: 'BUILD_SELECTOR_PREDICT')
}
stages {
stage('checkout') {
steps {
checkout([$class: 'GitSCM', branches: [[name: '*/master']], doGenerateSubmoduleConfigurations: false, extensions: [], submoduleCfg: [], userRemoteConfigs: [[url: 'https://git.wmi.amu.edu.pl/s426206/ium_426206.git']]])
}
}
stage('Copy artifact') {
steps {
copyArtifacts filter: 'my_model/input_example.json', fingerprintArtifacts: false, projectName: 's426206-training/master', selector: buildParameter('BUILD_SELECTOR_PREDICT')
}
}
stage('docker') {
steps {
script {
def img = docker.build('rokoch/ium:01')
img.inside('-v /tmp/mlruns:/tmp/mlruns') {
sh 'chmod +x mlflow_predict_registry.py'
sh 'python3 ./mlflow_predict_registry.py'
}
}
}
}
}
}