Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .github/workflows/pr-scan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: PR Sonar Scan

on:
pull_request:
branches: ["**"]

permissions:
id-token: write
contents: write

jobs:
sonarcloud-scan:
uses: AngelOneWealth/ci-common/.github/workflows/sonar-scan.yml@main
with:
pull-request-key: ${{ github.event.pull_request.number }}
pull-request-branch: ${{ github.head_ref }}
pull-request-base: ${{ github.base_ref }}
scm-revision: ${{ github.event.pull_request.head.sha }}
secrets:
SONAR_QUBE_ORG_TOKEN: ${{ secrets.SONAR_QUBE_ORG_TOKEN }}
22 changes: 22 additions & 0 deletions .github/workflows/sonar.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: SonarQube Scan
description: SonarQube Scan for PRs and main branch

on:
push:
branches:
- main
workflow_dispatch:

permissions:
id-token: write
contents: write

jobs:
sonar:
runs-on: org-runner
steps:
- name: SonarQube Scan
uses: AngelOneWealth/ci-common/.github/actions/sonarQube@main
with:
sonar-host : ${{ github.ref == 'refs/heads/gamma' && vars.SONAR_QUBE_HOST || vars.SONAR_QUBE_DEV_HOST }}
sonar-token: ${{ secrets.SONAR_QUBE_ORG_TOKEN }}