Create sonarqube.yml

This commit is contained in:
شركة خبير المحدودة 2025-08-17 19:03:56 +03:00 committed by GitHub
parent 0dd5173bc2
commit 6cbf060330
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 34 additions and 0 deletions

34
.github/workflows/sonarqube.yml vendored Normal file
View File

@ -0,0 +1,34 @@
name: SonarQube Analysis
on:
push:
branches: [ "dev_odex25_hr" ]
pull_request:
branches: [ "dev_odex25_hr" ]
jobs:
sonar:
runs-on: sonarqube
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install dependencies
run: |
pip install -r requirements.txt || true
pip install pylint-odoo || true
- name: SonarQube Scan
uses: SonarSource/sonarqube-scan-action@v2
with:
args: >
-Dsonar.projectKey=odex25_standard_modules_dev_odex25_hr
-Dsonar.sources=odex25_hr
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_HOST_URL: "https://sonar.odex.sa"