summaryrefslogtreecommitdiffstats
path: root/jjb/hicn/hicn.yaml
diff options
context:
space:
mode:
authorMauro Sardara <msardara@cisco.com>2022-08-10 19:08:42 +0200
committerMauro Sardara <msardara@cisco.com>2022-08-10 19:15:12 +0200
commit6c355d042a8eca527d2fe8b6743ac3aae15526c9 (patch)
tree53869c49c6ea42d0743c68b171fca6e790929772 /jjb/hicn/hicn.yaml
parent2ac685f154ae75ac0377cec312cd65d57240abbc (diff)
feat(hicn.yaml): add project and job-template for sonar scanner.
Signed-off-by: Mauro Sardara <msardara@cisco.com> Change-Id: I86c9baa94b6df0e2ec722e47e660d1d70fb71d39 Signed-off-by: Mauro Sardara <msardara@cisco.com>
Diffstat (limited to 'jjb/hicn/hicn.yaml')
-rw-r--r--jjb/hicn/hicn.yaml59
1 files changed, 45 insertions, 14 deletions
diff --git a/jjb/hicn/hicn.yaml b/jjb/hicn/hicn.yaml
index 2667a8ae..82bef0dc 100644
--- a/jjb/hicn/hicn.yaml
+++ b/jjb/hicn/hicn.yaml
@@ -77,6 +77,51 @@
- project-view
project-name: hicn
+- project:
+ name: hicn-sonar
+ jobs:
+ - hicn-sonar-scanner
+ project: hicn
+ sonarcloud: true
+ sonarcloud-project-organization: "{sonarcloud_project_organization}"
+ sonarcloud-api-token: "{sonarcloud_api_token}"
+ sonarcloud-project-key: "{sonarcloud_project_organization}-{project}"
+ stream:
+ - hicn:
+ branch: "master"
+
+- job-template:
+ name: hicn-sonar-scanner
+
+ project-type: freestyle
+ node: centos7-docker-4c-4g
+ concurrent: true
+
+ scm:
+ - gerrit-trigger-scm:
+ credentials-id: "jenkins-gerrit-credentials"
+ refspec: ""
+ choosing-strategy: "default"
+
+ wrappers:
+ - fdio-infra-wrappers:
+ build-timeout: "{build-timeout}"
+
+ triggers:
+ - gerrit-trigger-patch-merged:
+ name: "{project}"
+ branch: "{branch}"
+
+ builders:
+ - inject:
+ properties-content: |
+ SONAR_HOST_URL=https://sonarcloud.io
+ PROJECT_KEY={sonarcloud-project-key}
+ PROJECT_ORGANIZATION={sonarcloud-project-organization}
+ API_TOKEN={sonarcloud-api-token}
+ - shell: !include-raw-escape:
+ - ../scripts/hicn/sonar.sh
+
- job-template:
name: "hicn-checkstyle-verify-{stream}-{os}-{executor-arch}"
@@ -261,20 +306,6 @@
publishers:
- fdio-infra-publish
-- project:
- name: hicn-sonar
- project: hicn
- project-name: hicn
- mvn-settings: hicn-settings
- sonarcloud: true
- sonarcloud-project-organization: "{sonarcloud_project_organization}"
- sonarcloud-api-token: "{sonarcloud_api_token}"
- sonarcloud-project-key: "{sonarcloud_project_organization}_{project-name}"
- branch: master
- build-node: centos7-docker-2c-2g
- jobs:
- - gerrit-maven-sonar
-
- job-template:
name: "hicn-extras-verify-{stream}-{os}-{executor-arch}"