mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-21 14:55:51 +00:00
Update Jenkinsfile
This commit is contained in:
parent
18628bb833
commit
6cf1abc20c
1 changed files with 2 additions and 16 deletions
18
Jenkinsfile
vendored
18
Jenkinsfile
vendored
|
@ -30,25 +30,17 @@ pipeline {
|
|||
}
|
||||
stage('Build JAR') {
|
||||
steps {
|
||||
echo "Build the app."
|
||||
echo "Build app. Version: ${projectVersion}"
|
||||
sh "mvn clean package"
|
||||
}
|
||||
}
|
||||
stage('Quality Check') {
|
||||
steps {
|
||||
sh "mvn clean org.jacoco:jacoco-maven-plugin:prepare-agent install -Dmaven.test.failure.ignore=false"
|
||||
sh "mvn sonar:sonar -Dsonar.jacoco.reportPaths=target/coverage-reports/jacoco-unit.exec -Dsonar.host.url=http://sonarqube.cicd.svc:9000"
|
||||
// sh "mvn org.cyclonedx:cyclonedx-maven-plugin:makeBom"
|
||||
//dependencyTrackPublisher(artifact: 'target/bom.xml', artifactType: 'bom', projectName: "${appName}", projectVersion: "${projectVersion}", synchronous: false)
|
||||
}
|
||||
}
|
||||
stage('Build Image') {
|
||||
steps {
|
||||
script {
|
||||
echo "Build container image."
|
||||
openshift.withCluster() {
|
||||
openshift.withProject('cicd') {
|
||||
sh "oc start-build ${appName}-s2i-build --from-file=target/app.jar -n cicd --follow"
|
||||
sh "oc start-build ${appName}-build --from-file=target/app.jar -n cicd --follow"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -77,12 +69,6 @@ pipeline {
|
|||
}
|
||||
}
|
||||
}
|
||||
stage('Integration Tests') {
|
||||
steps {
|
||||
echo "Running Integration tests..."
|
||||
sh "mvn verify -Pfailsafe"
|
||||
}
|
||||
}
|
||||
stage("Tag UAT") {
|
||||
echo "Tag image to UAT"
|
||||
openshift.withCluster() {
|
||||
|
|
Loading…
Reference in a new issue