Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on Nov 23, 2021. It is now read-only.

Commit cba5bc7

Browse filesBrowse files
authored
Update Jenkinsfile-online, add stage('sonarqube analysis')
1 parent 65e8945 commit cba5bc7
Copy full SHA for cba5bc7

File tree

Expand file treeCollapse file tree

1 file changed

+16
-1
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+16
-1
lines changed
Open diff view settings
Collapse file

‎Jenkinsfile-online‎

Copy file name to clipboardExpand all lines: Jenkinsfile-online
+16-1Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,22 @@ pipeline {
3434
}
3535
}
3636
}
37-
37+
38+
stage('sonarqube analysis') {
39+
steps {
40+
container ('maven') {
41+
withCredentials([string(credentialsId: "$SONAR_CREDENTIAL_ID", variable: 'SONAR_TOKEN')]) {
42+
withSonarQubeEnv('sonar') {
43+
sh "mvn sonar:sonar -gs `pwd`/configuration/settings.xml -Dsonar.branch=$BRANCH_NAME -Dsonar.login=$SONAR_TOKEN"
44+
}
45+
}
46+
timeout(time: 1, unit: 'HOURS') {
47+
waitForQualityGate abortPipeline: true
48+
}
49+
}
50+
}
51+
}
52+
3853
stage ('build & push') {
3954
steps {
4055
container ('maven') {

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.