Update Jenkinsfile4

This commit is contained in:
s464903 2024-05-11 11:33:04 +02:00
parent d0b0d1cbc8
commit d603b5373c

View File

@ -33,30 +33,22 @@ pipeline {
steps { steps {
script { script {
docker.image('test-image').inside { docker.image('test-image').inside {
stage('Checkout') {
steps {
// Step: Clone the git repository // Step: Clone the git repository
checkout scm checkout scm
}
}
stage('Build') { // Step: Build
steps {
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}", withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
"KAGGLE_KEY=${params.KAGGLE_KEY}" ]) { "KAGGLE_KEY=${params.KAGGLE_KEY}" ]) {
sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME' sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME'
sh 'kaggle datasets list' sh 'kaggle datasets list'
} }
}
}
stage('Run ipynb script') { // Step: Run ipynb script
steps {
sh "mkdir /notebooks" sh "mkdir /notebooks"
sh "cp Biblioteka_DL_trenowanie.ipynb /notebooks/Biblioteka_DL_trenowanie.ipynb" sh "cp Biblioteka_DL_trenowanie.ipynb /notebooks/Biblioteka_DL_trenowanie.ipynb"
archiveArtifacts 'model.keras'
} // Step: Archive Artifacts
} stash includes: 'model.keras', name: 'artifacts'
} }
} }
} }