IUM_04 - update Jenkinsfile - test

This commit is contained in:
Paweł Łączkowski 2024-04-03 21:31:26 +02:00
parent 117d8115bf
commit f9e0ae9465
1 changed files with 6 additions and 8 deletions

14
Jenkinsfile vendored
View File

@ -3,7 +3,7 @@ pipeline {
dockerfile {
filename 'Dockerfile'
reuseNode true
args '-e KAGGLE_USERNAME=${KAGGLE_USERNAME} -e KAGGLE_KEY=${KAGGLE_KEY}'
args "-e KAGGLE_USERNAME=${KAGGLE_USERNAME} -e KAGGLE_KEY=${KAGGLE_KEY}"
}
}
@ -26,7 +26,7 @@ pipeline {
}
stages {
stage('Checkout repository') {
stage('Clone repository') {
steps {
checkout scm
}
@ -35,12 +35,10 @@ pipeline {
stage('Download dataset and preprocess data') {
steps {
script {
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}", "KAGGLE_KEY=${params.KAGGLE_KEY}"]) {
sh "echo ${params.KAGGLE_USERNAME}"
sh "chmod +x ./download_dataset.py"
sh "python3 ./download_dataset.py ${params.CUTOFF}"
archiveArtifacts artifacts: 'datasets/*', onlyIfSuccessful: true
}
sh "echo ${params.KAGGLE_USERNAME}"
sh "chmod +x ./download_dataset.py"
sh "python3 ./download_dataset.py ${params.CUTOFF}"
archiveArtifacts artifacts: 'datasets/*', onlyIfSuccessful: true
}
}
}