1. 增加gitlab-ci支持
This commit is contained in:
parent
64a993b793
commit
01bbee1b24
|
@ -4,22 +4,22 @@ stages :
|
||||||
- package
|
- package
|
||||||
|
|
||||||
# 代码质量检查
|
# 代码质量检查
|
||||||
sonarqube-check :
|
sonarqube-check:
|
||||||
stage : sonarqube-check
|
stage: sonarqube-check
|
||||||
tags :
|
tags:
|
||||||
- linux-maven
|
- linux-maven
|
||||||
image : maven:3-eclipse-temurin-17
|
image: maven:3.9.3-eclipse-temurin-17
|
||||||
variables :
|
variables:
|
||||||
SONAR_USER_HOME: "${CI_PROJECT_DIR}/.sonar" # Defines the location of the analysis task cache
|
SONAR_USER_HOME: "${CI_PROJECT_DIR}/.sonar" # Defines the location of the analysis task cache
|
||||||
GIT_DEPTH : "0" # Tells git to fetch all the branches of the project, required by the analysis task
|
GIT_DEPTH: "0" # Tells git to fetch all the branches of the project, required by the analysis task
|
||||||
cache :
|
cache:
|
||||||
key : "${CI_JOB_NAME}"
|
key: "${CI_JOB_NAME}"
|
||||||
paths:
|
paths:
|
||||||
- .sonar/cache
|
- .sonar/cache
|
||||||
script :
|
script:
|
||||||
- mvn verify sonar:sonar -DskipTests
|
- mvn verify sonar:sonar -DskipTests
|
||||||
allow_failure: true
|
allow_failure: true
|
||||||
only :
|
only:
|
||||||
- merge_requests
|
- merge_requests
|
||||||
- master
|
- master
|
||||||
- main
|
- main
|
||||||
|
|
Loading…
Reference in New Issue