fix kagle CLI
This commit is contained in:
parent
ab3ae0f05b
commit
adbdbef4b5
81
Jenkinsfile
vendored
81
Jenkinsfile
vendored
@ -1,48 +1,41 @@
|
||||
pipeline {
|
||||
agent any
|
||||
stages {
|
||||
stage('Preparation') {
|
||||
properties([
|
||||
parameters([
|
||||
string(
|
||||
defaultValue: 'tomaszzitkiewicz',
|
||||
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'
|
||||
node {
|
||||
stage('One') {
|
||||
|
||||
properties([
|
||||
parameters([
|
||||
string(defaultValue: '',
|
||||
description: 'Kaggle username',
|
||||
name: 'KAGGLE_USERNAME',
|
||||
trim: false),
|
||||
password(defaultValue: '',
|
||||
description: 'Kaggle token',
|
||||
name: 'KAGGLE_KEY'),
|
||||
string(defaultValue: '5000',
|
||||
description: 'Data cutoff',
|
||||
name: 'CUTOFF',
|
||||
trim: false)
|
||||
])
|
||||
]
|
||||
)
|
||||
])
|
||||
])
|
||||
}
|
||||
stage('Build') {
|
||||
// Run the maven build
|
||||
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
|
||||
"KAGGLE_KEY=${params.KAGGLE_KEY}" ]) {
|
||||
sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME'
|
||||
sh 'kaggle datasets list'
|
||||
stage('Two') {
|
||||
|
||||
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
|
||||
"KAGGLE_KEY=${params.KAGGLE_KEY}", "CUTOFF=${params.CUTOFF}" ]) {
|
||||
|
||||
|
||||
checkout([$class: 'GitSCM', branches: [[name: '*/master']], doGenerateSubmoduleConfigurations: false, extensions: [], submoduleCfg: [], userRemoteConfigs: [[url: 'https://git.wmi.amu.edu.pl/s440058/ium_440058']]])
|
||||
|
||||
|
||||
sh "chmod 777 ./bash.sh"
|
||||
sh "./bash.sh"
|
||||
|
||||
|
||||
|
||||
archiveArtifacts "courses.data.dev"
|
||||
archiveArtifacts "courses.data.test"
|
||||
archiveArtifacts "courses.data.train"
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('checkout: Check out from version control') {
|
||||
steps {
|
||||
git 'https://git.wmi.amu.edu.pl/s440058/ium_440058.git'
|
||||
}
|
||||
}
|
||||
stage('sh: Shell Script') {
|
||||
steps {
|
||||
sh 'chmod +x bash.sh'
|
||||
sh './bash.sh ${CUTOFF}'
|
||||
}
|
||||
}
|
||||
stage('archiveArtifacts') {
|
||||
steps {
|
||||
archiveArtifacts 'courses.data.test'
|
||||
archiveArtifacts 'courses.data.dev'
|
||||
archiveArtifacts 'courses.data.train'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user