Sonar Analysis - Scheduled #287
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow trigger a full Sonar analysis at regular interval | |
# Github actions command reference: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions | |
name: Sonar Analysis - Scheduled | |
on: | |
schedule: | |
- cron: '0 4 * * 1,3,5' # At 4AM, on Monday, Wednesday and Friday | |
jobs: | |
sonar-analysis: | |
name: Sonar Analysis | |
runs-on: ubuntu-latest | |
container: | |
image: jahia/cimg-mvn-cache:ga_cimg_openjdk_11.0.20-node | |
credentials: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_PASSWORD }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: jahia/jahia-modules-action/build@v2 | |
with: | |
nexus_username: ${{ secrets.NEXUS_USERNAME }} | |
nexus_password: ${{ secrets.NEXUS_PASSWORD }} | |
module_id: siteSettings | |
mvn_settings_filepath: '.github/maven.settings.xml' | |
- uses: jahia/jahia-modules-action/sonar-analysis@v2 | |
with: | |
primary_release_branch: master | |
build_artifacts: '' | |
github_pr_id: ${{github.event.number}} | |
sonar_url: ${{ secrets.SONAR_URL }} | |
sonar_token: ${{ secrets.SONAR_TOKEN }} | |
nvd_apikey: ${{ secrets.NVD_APIKEY }} | |
mvn_settings_filepath: '.github/maven.settings.xml' |