This commit is contained in:
Wojciech Lidwin 2023-04-04 14:42:11 +02:00
parent 222a82e2a3
commit fe8aed2045

5
Jenkinsfile vendored
View File

@ -27,7 +27,7 @@ node {
} }
stage('Dockerfile'){ stage('Dockerfile'){
def testImage = docker.image("test-image") def testImage = docker.image("test-image")
sh "chmod +x -R ${env.WORKSPACE}" sh "chmod u+x ${env.WORKSPACE}"
testImage.inside("""-w=${WORKSPACE} """){ testImage.inside("""-w=${WORKSPACE} """){
stage('Shell Script') { stage('Shell Script') {
// Run the maven build // Run the maven build
@ -35,8 +35,7 @@ node {
"KAGGLE_KEY=${params.KAGGLE_KEY}", "KAGGLE_KEY=${params.KAGGLE_KEY}",
"CUTOFF=${params.CUTOFF}" ]) { "CUTOFF=${params.CUTOFF}" ]) {
sh '''echo KAGGLE_USERNAME: $KAGGLE_USERNAME''' sh '''echo KAGGLE_USERNAME: $KAGGLE_USERNAME'''
sh '''echo KAGGLE_USERNAME: $KAGGLE_KEY''' sh "sudo kaggle datasets download -d sohier/crime-in-baltimore"
sh "kaggle datasets download -d sohier/crime-in-baltimore"
sh "unzip crime-in-baltimore.zip" sh "unzip crime-in-baltimore.zip"
sh 'python3 data.py' sh 'python3 data.py'
archiveArtifacts artifacts: 'BPD_Part_1_Victim_Based_Crime_Data.csv,baltimore_train.csv, baltimore_test.csv, baltimore_dev.csv' archiveArtifacts artifacts: 'BPD_Part_1_Victim_Based_Crime_Data.csv,baltimore_train.csv, baltimore_test.csv, baltimore_dev.csv'