Files
test-app/.gitea/workflows/sonarqube.yml
T
gitea_admin 15e471cc20
SonarQube Analysis / sonar (push) Successful in 51s
Fix: Sonarqube workflow project properties
2026-05-04 07:19:33 +00:00

37 lines
897 B
YAML

name: SonarQube Analysis
on:
push:
branches:
- main
jobs:
sonar:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Docker CLI
run: |
apt-get update
apt-get install -y docker.io
- name: Debug workspace
run: |
pwd
ls -la
- name: Run SonarScanner
run: |
docker run --rm \
--network dev-platform_default \
-e SONAR_HOST_URL="${{ vars.SONAR_HOST_URL }}" \
-e SONAR_TOKEN="${{ secrets.SONAR_TOKEN }}" \
-v "$PWD:/usr/src" \
sonarsource/sonar-scanner-cli \
-Dsonar.projectKey="${{ vars.SONAR_PROJECT_KEY }}" \
-Dsonar.projectName="${{ vars.SONAR_PROJECT_KEY }}" \
-Dsonar.sources=. \
-Dsonar.sourceEncoding=UTF-8