36 lines
1.0 KiB
Plaintext
36 lines
1.0 KiB
Plaintext
pipeline {
|
|
agent any
|
|
//Definijuemy parametry, ktore bedzie mozna podac podczas wywolywania zadania
|
|
parameters {
|
|
buildSelector (
|
|
name: 'BUILD_SELECTOR',
|
|
defaultSelector: lastSuccessful(),
|
|
description: 'Which build to use for copying artifacts?',
|
|
)
|
|
}
|
|
stages {
|
|
stage('Load Artifact') {
|
|
steps {
|
|
script {
|
|
copyArtifacts fingerprintArtifacts: true, projectName: 's452627-create-dataset', selector: buildParameter("BUILD_SELECTOR")
|
|
}
|
|
}
|
|
}
|
|
stage('Run Script') {
|
|
steps {
|
|
script {
|
|
//sh "chmod +x -R ${env.WORKSPACE}"
|
|
//sh './make_statistic.sh | tee output_statistic.txt'
|
|
sh 'docker build . -t jhenyk/ium:latest'
|
|
sh 'docker run -p jhenyk/ium:latest'
|
|
}
|
|
}
|
|
|
|
}
|
|
stage('Archive Output') {
|
|
steps {
|
|
archiveArtifacts 'output_statistic.txt'
|
|
}
|
|
}
|
|
}
|
|
} |