4 # yamllint disable-line rule:truthy
9 description: "Branch that change is against"
13 description: "The ID for the change"
17 description: "The Gerrit number"
21 description: "URL to the change"
25 description: "Type of Gerrit event"
28 GERRIT_PATCHSET_NUMBER:
29 description: "The patch number for the change"
32 GERRIT_PATCHSET_REVISION:
33 description: "The revision sha"
37 description: "Project in Gerrit"
41 description: "Gerrit refspec of change"
46 description: "Sonar Cloud access token"
50 # yamllint disable-line rule:line-length
51 group: gerrit-merge-${{ github.workflow }}-${{ github.event.inputs.GERRIT_CHANGE_ID || github.run_id }}
52 cancel-in-progress: true
56 runs-on: ubuntu-latest
58 - name: Notify job start
59 # yamllint disable-line rule:line-length
60 uses: lfit/gerrit-review-action@9627b9a144f2a2cad70707ddfae87c87dce60729 # v0.8
62 host: ${{ vars.GERRIT_SERVER }}
63 username: ${{ vars.GERRIT_SSH_USER }}
64 key: ${{ secrets.GERRIT_SSH_PRIVKEY }}
65 known_hosts: ${{ vars.GERRIT_KNOWN_HOSTS }}
66 gerrit-change-number: ${{ inputs.GERRIT_CHANGE_NUMBER }}
67 gerrit-patchset-number: ${{ inputs.GERRIT_PATCHSET_NUMBER }}
70 - name: Allow replication
73 call-cmake-sonarcloud:
75 # yamllint disable-line rule:line-length
76 uses: lfit/releng-reusable-workflows/.github/workflows/composed-cmake-sonar-cloud.yaml@main
78 GERRIT_BRANCH: ${{ inputs.GERRIT_BRANCH }}
79 GERRIT_CHANGE_ID: ${{ inputs.GERRIT_CHANGE_ID }}
80 GERRIT_CHANGE_NUMBER: ${{ inputs.GERRIT_CHANGE_NUMBER }}
81 GERRIT_CHANGE_URL: ${{ inputs.GERRIT_CHANGE_URL }}
82 GERRIT_EVENT_TYPE: ${{ inputs.GERRIT_EVENT_TYPE }}
83 GERRIT_PATCHSET_NUMBER: ${{ inputs.GERRIT_PATCHSET_NUMBER }}
84 GERRIT_PATCHSET_REVISION: ${{ inputs.GERRIT_PATCHSET_REVISION }}
85 GERRIT_PROJECT: ${{ inputs.GERRIT_PROJECT }}
86 GERRIT_REFSPEC: ${{ inputs.GERRIT_REFSPEC }}
88 # yamllint disable-line rule:line-length
89 PRE_BUILD_SCRIPT_URL: "https://raw.githubusercontent.com/lfit/releng-global-jjb/master/shell/cmake-sonar.sh"
91 -Dsonar.organization=o-ran-sc
92 -Dsonar.projectKey=o-ran-sc_ric-app-mc
93 -Dsonar.projectName=ric-app-mc
94 -Dsonar.build.sourceEncoding=UTF-8
95 -Dsonar.sources=sidecars/listener/src,mc-core/mc/mcnib
96 -Dsonar.cfamily.build-wrapper-output="${GITHUB_WORKSPACE}/bw-output"
97 -Dsonar.cfamily.gcov.reportsPath=/tmp/gcov_rpts
98 -Dsonar.cfamily.threads=2
100 SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
104 needs: [notify, call-cmake-sonarcloud]
105 runs-on: ubuntu-latest
107 - name: Get workflow conclusion
108 uses: technote-space/workflow-conclusion-action@v3
109 - name: Report workflow conclusion
110 # yamllint disable-line rule:line-length
111 uses: lfit/gerrit-review-action@9627b9a144f2a2cad70707ddfae87c87dce60729 # v0.8
113 host: ${{ vars.GERRIT_SERVER }}
114 username: ${{ vars.GERRIT_SSH_USER }}
115 key: ${{ secrets.GERRIT_SSH_PRIVKEY }}
116 known_hosts: ${{ vars.GERRIT_KNOWN_HOSTS }}
117 gerrit-change-number: ${{ inputs.GERRIT_CHANGE_NUMBER }}
118 gerrit-patchset-number: ${{ inputs.GERRIT_PATCHSET_NUMBER }}
119 vote-type: ${{ env.WORKFLOW_CONCLUSION }}