zmienne
This commit is contained in:
parent
b1b468bf93
commit
25fda138b9
81
Jenkinsfile
vendored
81
Jenkinsfile
vendored
@ -1,43 +1,42 @@
|
|||||||
node {
|
pipeline {
|
||||||
stage('One') {
|
agent any
|
||||||
|
parameters {
|
||||||
properties([
|
string(
|
||||||
parameters([
|
defaultValue: '0',
|
||||||
string(defaultValue: '',
|
description: 'Umożliwia zdefiniowanie wielkości odcięcia zbioru danych.',
|
||||||
description: 'Kaggle username',
|
name: 'CUTOFF',
|
||||||
name: 'KAGGLE_USERNAME',
|
trim: false
|
||||||
trim: false),
|
)
|
||||||
password(defaultValue: '',
|
string(
|
||||||
description: 'Kaggle token',
|
defaultValue: 'rokoch',
|
||||||
name: 'KAGGLE_KEY')
|
description: 'Kaggle username',
|
||||||
])
|
name: 'KAGGLE_USERNAME',
|
||||||
]
|
trim: false
|
||||||
)
|
)
|
||||||
stage('Two') {
|
password(
|
||||||
|
defaultValue: '',
|
||||||
|
description: 'Kaggle token taken from kaggle.json file, as described in https://github.com/Kaggle/kaggle-api#api-credentials',
|
||||||
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
|
name: 'KAGGLE_KEY'
|
||||||
"KAGGLE_KEY=${params.KAGGLE_KEY}"]) {
|
)
|
||||||
|
}
|
||||||
|
stages {
|
||||||
checkout([$class: 'GitSCM', branches: [[name: '*/master']], doGenerateSubmoduleConfigurations: false, extensions: [], submoduleCfg: [], userRemoteConfigs: [[url: 'https://git.wmi.amu.edu.pl/s426206/ium_426206.git']]])
|
stage('checkout') {
|
||||||
|
steps {
|
||||||
checkout scm
|
checkout([$class: 'GitSCM', branches: [[name: '*/master']], doGenerateSubmoduleConfigurations: false, extensions: [], submoduleCfg: [], userRemoteConfigs: [[url: 'https://git.wmi.amu.edu.pl/s426206/ium_426206.git']]])
|
||||||
|
}
|
||||||
def image = docker.build("image")
|
}
|
||||||
image.inside {
|
|
||||||
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
|
stage('docker') {
|
||||||
"KAGGLE_KEY=${params.KAGGLE_KEY}"]) {
|
agent { dockerfile true }
|
||||||
sh './skrypt.sh'
|
steps {
|
||||||
}
|
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
|
||||||
|
"KAGGLE_KEY=${params.KAGGLE_KEY}"]) {
|
||||||
|
sh 'ls -l'
|
||||||
|
sh 'chmod +x skrypt.sh'
|
||||||
|
sh './skrypt.sh 0'
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user