ium_470623/jenkinsfile
2022-03-28 00:34:36 +02:00

43 lines
1.5 KiB
Plaintext

pipeline {
agent any
parameters {
string(
defaultValue: 'ikami1',
description: 'Kaggle username',
name: 'KAGGLE_USERNAME',
trim: false
)
password(
defaultValue: 'c70ff184133bfabb351608b128e76cd2',
description: 'Kaggle token taken from kaggle.json file, as described in https://github.com/Kaggle/kaggle-api#api-credentials',
name: 'KAGGLE_KEY'
)
}
environment {
KAGGLE_USERNAME="$params.KAGGLE_USERNAME"
KAGGLE_KEY="$params.KAGGLE_KEY"
}
stages {
stage('Test stage') {
steps {
echo 'Hello world! Some test text - added text'
}
}
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}"]) {
sh "echo KAGGLE_USERNAME: $KAGGLE_USERNAME"
sh "./download.sh"
archiveArtifacts artifacts: "steel_industry_data_test.csv, steel_industry_data_dev.csv, steel_industry_data_train.csv"
}
}
}
}
}