diff --git a/lab5/create/Jenkinsfile b/lab5/create/Jenkinsfile index f6a795b..099cb46 100644 --- a/lab5/create/Jenkinsfile +++ b/lab5/create/Jenkinsfile @@ -14,17 +14,17 @@ pipeline { } stage('docker') { agent { - dockerfile { - filename 'Dockerfile' - args '-e KAGGLE_USERNAME=${params.KAGGLE_USERNAME} -e KAGGLE_KEY=${params.KAGGLE_KEY}' - } + dockerfile true } stages { stage('script') { steps { - sh ''' - chmod +x script.sh - ./script.sh''' + withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}", + "KAGGLE_KEY=${params.KAGGLE_KEY}" ]) { + sh ''' + chmod +x script.sh + ./script.sh''' + } } } stage('archive artifact') {