Conversation
e39587a to
e40dbb5
Compare
|
/ok-to-test e40dbb5 |
Signed-off-by: Arjun <agadiyar@nvidia.com>
| - if: $CI_COMMIT_BRANCH == 'main' | ||
| allow_failure: true | ||
| script: | ||
| - sonar-scanner -Dsonar.host.url="${SONAR_HOST_URL}" -Dsonar.projectKey=gpu-operator -Dsonar.projectName=gpu-operator -Dsonar.sources=. |
There was a problem hiding this comment.
What does this do exactly? Is this performing a static analysis scan and uploading the results somewhere? What commit SHA is SonarQube scanning?
With prior static analysis tools, we were able to schedule regular scans without having to add jobs to our CI. Can we do that with SonarQube and avoid having to add CI changes to all of our repositories?
There was a problem hiding this comment.
Yes this is performing the scan and updating the sonar gpu-operator dashboard with the results. Unfortunately, the SonarQube dashboard does not provide a way to schedule regular scans; we need to trigger with CI/CD. I can try to see if I can move the scan command into the pre-existing NSPECT job if that is preferred.
Description
This change creates a job to update sonarqube for the gpu-operator repository. It will only run on the main branch to ensure the sonarqube version is up to date. It will use the sonarsource/sonar-scanner-cli:11 image.
Checklist
make lint)make validate-generated-assets)make validate-modules)Testing
Pipeline was tested manually on Gitlab test branch; verified that sonarqube report was being generated online.