2022-03-21 10:26:02 +01:00
|
|
|
pipeline {
|
|
|
|
agent any
|
2022-03-21 10:46:50 +01:00
|
|
|
parameters {
|
|
|
|
string(
|
|
|
|
defaultValue: 'marcinkostrzewski',
|
|
|
|
description: 'Kaggle username',
|
|
|
|
name: 'KAGGLE_USERNAME',
|
|
|
|
trim: false
|
|
|
|
)
|
|
|
|
password(
|
|
|
|
defaultValue: '',
|
|
|
|
description: 'Kaggle token taken from kaggle.json file, as described in https://github.com/Kaggle/kaggle-api#api-credentials',
|
|
|
|
name: 'KAGGLE_KEY'
|
|
|
|
)
|
|
|
|
}
|
2022-03-21 10:26:02 +01:00
|
|
|
stages {
|
2022-03-21 10:46:50 +01:00
|
|
|
stage('Install dependencies') {
|
|
|
|
steps {
|
|
|
|
sh "pip install --user -r requirements.txt"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
stage('Fetch and split dataset') {
|
2022-03-21 10:26:02 +01:00
|
|
|
steps {
|
2022-03-27 23:19:42 +02:00
|
|
|
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
|
|
|
|
"KAGGLE_KEY=${params.KAGGLE_KEY}" ]) {
|
|
|
|
sh "chmod u+x ./download_dataset.sh"
|
|
|
|
sh "./download_dataset.sh"
|
2022-03-21 10:46:50 +01:00
|
|
|
}
|
2022-03-21 10:26:02 +01:00
|
|
|
}
|
|
|
|
}
|
2022-05-05 21:38:46 +02:00
|
|
|
}
|
|
|
|
post {
|
|
|
|
always {
|
|
|
|
archiveArtifacts artifacts: 'data/*',
|
|
|
|
onlyIfSuccessful: true
|
2022-03-27 23:25:26 +02:00
|
|
|
}
|
|
|
|
}
|
2022-03-21 10:46:50 +01:00
|
|
|
}
|