ium_470623/jenkinsfile

50 lines
1.7 KiB
Plaintext
Raw Normal View History

2022-03-21 10:51:30 +01:00
pipeline {
2022-04-11 00:40:48 +02:00
agent {
dockerfile true
}
parameters {
string(
defaultValue: 'ikami1',
description: 'Kaggle username',
name: 'KAGGLE_USERNAME',
trim: false
)
password(
2022-04-11 00:40:48 +02:00
defaultValue: '',
description: 'Kaggle token taken from kaggle.json file, as described in https://github.com/Kaggle/kaggle-api#api-credentials',
name: 'KAGGLE_KEY'
)
string(
defaultValue: '35041',
description: 'CUTOFF parameter',
name: 'CUTOFF')
}
environment {
KAGGLE_USERNAME="$params.KAGGLE_USERNAME"
KAGGLE_KEY="$params.KAGGLE_KEY"
}
2022-03-21 10:51:30 +01:00
stages {
stage('Test stage') {
2022-03-21 10:51:30 +01:00
steps {
2022-03-21 10:58:23 +01:00
echo 'Hello world! Some test text - added text'
2022-03-21 10:51:30 +01:00
}
}
stage('Checkout') {
steps {
checkout([$class: 'GitSCM', branches: [[name: '*/master']], extensions: [], userRemoteConfigs: [[credentialsId: 's470623', url: 'https://git.wmi.amu.edu.pl/s470623/ium_470623.git']]])
}
}
stage('Shell script') {
steps {
sh 'chmod u+x ./download.sh'
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
"KAGGLE_KEY=${params.KAGGLE_KEY}",
"CUTOFF=${params.CUTOFF}"]) {
2022-04-11 00:40:48 +02:00
sh "./download_dataset.sh"
sh "python3 process_dataset.py"
archiveArtifacts artifacts: "steel_industry_data_test.csv, steel_industry_data_dev.csv, steel_industry_data_train.csv"
}
}
}
2022-03-21 10:51:30 +01:00
}
}