Skip to content

Commit 27a44fb

Browse files
authored
Chore: [AEA-0000] - fix mavan cache before running sonar (#53)
## Summary - Routine Change ### Details - clear maven cache before running sonar
1 parent b933ef1 commit 27a44fb

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

.gitallowed

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ password: \${{ secrets\.GITHUB_TOKEN }}
55
def __init__\(self, token: str, owner: str, repo: str.*
66
self\.token = token
77
token = os\.environ\.get\(\"GH_TOKEN\"\)
8+
\-Dsonar\.token=\"\$SONAR_TOKEN\"

.github/workflows/quality-checks.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,14 @@ jobs:
328328

329329
- name: Run SonarQube analysis
330330
if: ${{ steps.check_languages.outputs.uses_java == 'true' && env.SONAR_TOKEN_EXISTS == 'true' }}
331-
run: mvn sonar:sonar -Dsonar.login=${{ secrets.SONAR_TOKEN }}
331+
run: |
332+
# issues with sonar scanner and sslcontext-kickstart 9.1.0, forcing re-download
333+
rm -rf ~/.m2/repository/io/github/hakky54/sslcontext-kickstart/9.1.0
334+
mvn dependency:get -U -Dartifact=io.github.hakky54:sslcontext-kickstart:9.1.0
335+
# run sonar scan
336+
mvn sonar:sonar -Dsonar.token="$SONAR_TOKEN"
337+
env:
338+
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
332339

333340
- name: SonarCloud Scan
334341
uses: SonarSource/sonarqube-scan-action@a31c9398be7ace6bbfaf30c0bd5d415f843d45e9

0 commit comments

Comments
 (0)