mirror of
https://github.com/hwanny1128/HGZero.git
synced 2025-12-06 06:46:24 +00:00
Jenkinsfile: SonarQube 관련 코드 모두 제거
- SKIP_SONARQUBE 파라미터 제거 - SONAR_TOKEN credential 제거 - SonarQube Analysis stage 전체 제거 - 빌드 파이프라인 단순화
This commit is contained in:
parent
ec4a23cc33
commit
d7742d60c3
33
Jenkinsfile
vendored
33
Jenkinsfile
vendored
@ -7,11 +7,6 @@ pipeline {
|
||||
choices: ['dev', 'staging', 'prod'],
|
||||
description: 'Target environment'
|
||||
)
|
||||
choice(
|
||||
name: 'SKIP_SONARQUBE',
|
||||
choices: ['true', 'false'],
|
||||
description: 'Skip SonarQube Analysis'
|
||||
)
|
||||
}
|
||||
|
||||
environment {
|
||||
@ -33,7 +28,6 @@ pipeline {
|
||||
// Credentials
|
||||
ACR_CREDENTIALS = credentials('acr-credentials')
|
||||
DOCKERHUB_CREDENTIALS = credentials('dockerhub-credentials')
|
||||
SONAR_TOKEN = credentials('sonar-token')
|
||||
GIT_CREDENTIALS = credentials('git-credentials')
|
||||
}
|
||||
|
||||
@ -100,33 +94,6 @@ pipeline {
|
||||
}
|
||||
}
|
||||
|
||||
stage('SonarQube Analysis') {
|
||||
when {
|
||||
expression { params.SKIP_SONARQUBE == 'false' }
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
echo "🔍 Running SonarQube Analysis..."
|
||||
|
||||
withSonarQubeEnv('SonarQube') {
|
||||
env.SERVICES.split().each { service ->
|
||||
echo "Analyzing ${service}..."
|
||||
sh """
|
||||
./gradlew :${service}:test :${service}:jacocoTestReport :${service}:sonar \
|
||||
-Dsonar.projectKey=hgzero-${service}-${params.ENVIRONMENT} \
|
||||
-Dsonar.projectName=hgzero-${service}-${params.ENVIRONMENT} \
|
||||
-Dsonar.host.url=\${SONAR_HOST_URL} \
|
||||
-Dsonar.token=\${SONAR_TOKEN} \
|
||||
-Dsonar.java.binaries=build/classes/java/main \
|
||||
-Dsonar.coverage.jacoco.xmlReportPaths=build/reports/jacoco/test/jacocoTestReport.xml \
|
||||
-Dsonar.exclusions=**/config/**,**/entity/**,**/dto/**,**/*Application.class,**/exception/**
|
||||
"""
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Archive Artifacts') {
|
||||
steps {
|
||||
script {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user