diff --git a/.gitea/workflows/sonarqube.yml b/.gitea/workflows/sonarqube.yml index 6ce5e1b..303d49f 100644 --- a/.gitea/workflows/sonarqube.yml +++ b/.gitea/workflows/sonarqube.yml @@ -31,23 +31,17 @@ jobs: dotnet tool install --global dotnet-sonarscanner echo "$HOME/.dotnet/tools" >> $GITHUB_PATH - - name: Debug - run: | - echo "Host URL is: ${{ secrets.SONAR_HOST_URL }}" - echo "Token length: ${#SONAR_TOKEN}" - env: - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - - name: Debug Connectivity - run: | - echo "Testing host URL: ${SONAR_HOST_URL}" - curl -sI "${SONAR_HOST_URL}/api/system/status" || echo "curl failed" - echo "---" - curl -s -u "${SONAR_TOKEN}:" "${SONAR_HOST_URL}/api/authentication/validate" env: - SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - + HOST: ${{ secrets.SONAR_HOST_URL }} + TOKEN: ${{ secrets.SONAR_TOKEN }} + run: | + echo "Token length: ${#TOKEN}" + curl -s -o /dev/null -w "status endpoint: %{http_code}\n" "$HOST/api/system/status" + echo "Validate response:" + curl -s -u "$TOKEN:" "$HOST/api/authentication/validate" + echo + - name: SonarScanner Begin run: | dotnet sonarscanner begin \