From d603b5373c024d1509f3e0d2cb616c7d564cb940 Mon Sep 17 00:00:00 2001 From: s464903 Date: Sat, 11 May 2024 11:33:04 +0200 Subject: [PATCH] Update Jenkinsfile4 --- Jenkinsfile4 | 34 +++++++++++++--------------------- 1 file changed, 13 insertions(+), 21 deletions(-) diff --git a/Jenkinsfile4 b/Jenkinsfile4 index acae973..d574b7e 100644 --- a/Jenkinsfile4 +++ b/Jenkinsfile4 @@ -33,30 +33,22 @@ pipeline { steps { script { docker.image('test-image').inside { - stage('Checkout') { - steps { - // Step: Clone the git repository - checkout scm - } - } + // Step: Clone the git repository + checkout scm - stage('Build') { - steps { - withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}", - "KAGGLE_KEY=${params.KAGGLE_KEY}" ]) { - sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME' - sh 'kaggle datasets list' - } - } + // Step: Build + withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}", + "KAGGLE_KEY=${params.KAGGLE_KEY}" ]) { + sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME' + sh 'kaggle datasets list' } - stage('Run ipynb script') { - steps { - sh "mkdir /notebooks" - sh "cp Biblioteka_DL_trenowanie.ipynb /notebooks/Biblioteka_DL_trenowanie.ipynb" - archiveArtifacts 'model.keras' - } - } + // Step: Run ipynb script + sh "mkdir /notebooks" + sh "cp Biblioteka_DL_trenowanie.ipynb /notebooks/Biblioteka_DL_trenowanie.ipynb" + + // Step: Archive Artifacts + stash includes: 'model.keras', name: 'artifacts' } } }