Update: props sonarqube #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
push: | |
branches: | |
- master | |
- MO827 | |
workflow_dispatch: # Permite rodar manualmente | |
jobs: | |
build: | |
name: Build and analyze | |
runs-on: self-hosted | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 # Evita shallow clone, importante para análise completa | |
- uses: sonarsource/sonarqube-scan-action@v3 | |
env: | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} | |
# Falha o job se o Quality Gate estiver vermelho (opcional) | |
# - uses: sonarsource/sonarqube-quality-gate-action@master | |
# timeout-minutes: 5 | |
# env: | |
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} |