2022-06-25 15:26:56 +02:00
|
|
|
pipeline {
|
|
|
|
agent {
|
2022-06-26 13:08:16 +02:00
|
|
|
dockerfile {
|
|
|
|
additionalBuildArgs "--build-arg KAGGLE_USERNAME=${params.KAGGLE_USERNAME} --build-arg KAGGLE_KEY=${params.KAGGLE_KEY} --build-arg CUTOFF=${params.CUTOFF} -t sebastianwalesa"
|
2022-06-25 15:26:56 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
parameters {
|
|
|
|
buildSelector(
|
|
|
|
defaultSelector: lastSuccessful(),
|
|
|
|
description: 'Which build to use for copying artifacts for predict',
|
|
|
|
name: 'BUILD_SELECTOR')
|
|
|
|
string(
|
|
|
|
defaultValue: '{\\"inputs\\": [900.0]}',
|
|
|
|
description: 'Input file',
|
|
|
|
name: 'INPUT',
|
|
|
|
trim: true
|
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
stages {
|
|
|
|
stage('Copy Artifacts') {
|
|
|
|
steps {
|
|
|
|
copyArtifacts projectName: 's444409-training/main', selector: buildParameter('BUILD_SELECTOR')
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
stage('Prediction') {
|
|
|
|
steps {
|
|
|
|
sh "echo ${params.INPUT} > input_example.json"
|
2022-06-26 12:49:05 +02:00
|
|
|
sh "python3 prediction-s444409.py"
|
2022-06-25 15:26:56 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|