diff --git a/Jenkinsfile-stats-Docker b/Jenkinsfile-stats-Docker new file mode 100644 index 0000000..b39237c --- /dev/null +++ b/Jenkinsfile-stats-Docker @@ -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" + } +} \ No newline at end of file