From 90f6348e4d966adbcdb7b1d721e48e1b0066eded Mon Sep 17 00:00:00 2001 From: Leonid Pershin Date: Fri, 31 Oct 2025 18:28:46 +0300 Subject: [PATCH] Update SonarQube workflow to trigger on push events for all branches and modify project key references in API calls for consistency. --- .github/workflows/sonarqube.yml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/.github/workflows/sonarqube.yml b/.github/workflows/sonarqube.yml index 90e570b..a2c40f5 100644 --- a/.github/workflows/sonarqube.yml +++ b/.github/workflows/sonarqube.yml @@ -1,11 +1,9 @@ name: SonarQube on: - pull_request: + push: branches: - - master - - main - types: [opened, synchronize, reopened] + - '*' jobs: build: @@ -78,7 +76,7 @@ jobs: # Get Quality Gate status using jq for proper JSON parsing RESPONSE=$(curl -s -u "${{ secrets.SONAR_TOKEN }}:" \ - "${{ secrets.SONAR_HOST_URL }}/api/qualitygates/project_status?projectKey=Mrleo1nid.aiimages") + "${{ secrets.SONAR_HOST_URL }}/api/qualitygates/project_status?projectKey=AIImages") echo "API Response: $RESPONSE" @@ -94,7 +92,7 @@ jobs: if [ "$QUALITY_GATE_STATUS" != "OK" ]; then echo "❌ Quality Gate failed! Status: $QUALITY_GATE_STATUS" echo "Please check the SonarQube dashboard for details:" - echo "${{ secrets.SONAR_HOST_URL }}/dashboard?id=Mrleo1nid.aiimages" + echo "${{ secrets.SONAR_HOST_URL }}/dashboard?id=AIImages" exit 1 else echo "✅ Quality Gate passed!"