From d606d60ec06cecc9ae3d548449a73b0272ac5168 Mon Sep 17 00:00:00 2001 From: "bartosz.maslanka.consultant" Date: Fri, 21 Apr 2023 16:05:54 +0200 Subject: [PATCH] jen --- Jenkinsfile | 60 ++++++++++++++++++++--------------------------------- 1 file changed, 22 insertions(+), 38 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 625e1fa..6777d32 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,42 +1,26 @@ -pipeline { - 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('Preparation') { + properties([ + parameters([ + string( + defaultValue: 'bartekmalanka', + 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' + ) ]) - } - stage('Checkout') { - steps { - git branch: 'master', url: 'https://git.wmi.amu.edu.pl/s487184/ium_487184' - } - } - - stage('Run Script') { - steps { - withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}", + ]) + } + stage('Build') { + // Run the maven build + withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}", "KAGGLE_KEY=${params.KAGGLE_KEY}" ]) { - sh 'kaggle datasets download -d elakiricoder/gender-classification-dataset > output.txt' - - } - } - } - - stage('Archive Artifacts') { - steps { - archiveArtifacts 'output.txt' - } + sh 'kaggle datasets download -d elakiricoder/gender-classification-dataset > output.txt' } } -} +} \ No newline at end of file