-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add Sonar analysis to build pipeline (#324)
- Loading branch information
1 parent
050da9a
commit 6f4327b
Showing
3 changed files
with
38 additions
and
0 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: sonar | ||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
- v* | ||
paths: | ||
- 'frontend/**' | ||
defaults: | ||
run: | ||
working-directory: frontend | ||
jobs: | ||
sonar-analysis: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Sonar analysis | ||
uses: sonarsource/sonarcloud-github-action@master | ||
with: | ||
projectBaseDir: frontend | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
sonar.organization=szatyinadam | ||
sonar.projectKey=szatyinadam_signoz | ||
|
||
# relative paths to source directories. More details and properties are described | ||
# in https://sonarcloud.io/documentation/project-administration/narrowing-the-focus/ | ||
sonar.sources=./src |