Add 'Jenkinsfile-stats-Docker'

This commit is contained in:
Wojciech Mikołajski 2023-04-21 08:23:45 +02:00
parent fb6f2b7cd8
commit 7bc522b6c9

27
Jenkinsfile-stats-Docker Normal file
View File

@ -0,0 +1,27 @@
node {
stage('Preparation') {
properties([
parameters([
buildSelector(
defaultSelector: lastSuccessful(),
description: 'Which build to use for copying artifacts',
name: 'BUILD_SELECTOR')
])
])
}
stage('checkout: Check out from version control') {
checkout scm
}
stage('Copy Artifacts') {
copyArtifacts fingerprintArtifacts: true, projectName: 's487182-create-dataset', selector: buildParameter('BUILD_SELECTOR')
archiveArtifacts artifacts: 'waterQuality.csv, output.txt'
}
stage('sh: Shell Script') {
sh 'python3 dataset_stats.py > output.txt'
archiveArtifacts artifacts: 'output.txt'
}
stage('Run command in Docker container') {
sh "docker run -v app/body_performance_processed.csv wujt89/ium:1 python3 ./create_dataset.py > output.txt"
}
}