Skip to content

Commit 2081c42

Browse files
SQRP-122 Reference SonarQube Community Build
1 parent 2a53a0f commit 2081c42

5 files changed

+22
-13
lines changed

README.md

+22-13
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,25 @@
1-
# SonarQube Server Quality Gate check [![QA](https://github.com/SonarSource/sonarqube-quality-gate-action/actions/workflows/run-qa.yml/badge.svg)](https://github.com/SonarSource/sonarqube-quality-gate-action/actions/workflows/run-qa.yml)
1+
# SonarQube Quality Gate check [![QA](https://github.com/SonarSource/sonarqube-quality-gate-action/actions/workflows/run-qa.yml/badge.svg)](https://github.com/SonarSource/sonarqube-quality-gate-action/actions/workflows/run-qa.yml)
22

3-
Check the Quality Gate of your code with [SonarQube Server](https://www.sonarsource.com/products/sonarqube/) to ensure your code meets your own quality standards before you release or deploy new features.
3+
Check the Quality Gate of your code with [SonarQube Server](https://www.sonarsource.com/products/sonarqube/) and [SonarQube Community Build](https://www.sonarsource.com/open-source-editions/sonarqube-community-edition/) to ensure your code meets your own quality standards before you release or deploy new features.
44

5-
<img src="./images/SonarQubeServer.png">
5+
<picture>
6+
<source media="(prefers-color-scheme: dark)" srcset="./images/SonarQubeServer_dark.png">
7+
<img alt="Text changing depending on mode. Light: 'So light!' Dark: 'So dark!'" src="./images/SonarQubeServer_light.png">
8+
</picture>
9+
<picture>
10+
<source media="(prefers-color-scheme: dark)" srcset="./images/SQ_Logo_Community_dark.png">
11+
<img alt="Text changing depending on mode. Light: 'So light!' Dark: 'So dark!'" src="./images/SQ_Logo_Community_light.png">
12+
</picture>
613

7-
SonarQube Server is the leading product for Continuous Code Quality & Code Security. It supports most popular programming languages, including Java, JavaScript, TypeScript, C#, Python, C, C++, and many more.
14+
[SonarQube Server](https://www.sonarsource.com/products/sonarqube/) and [SonarQube Community Build](https://www.sonarsource.com/open-source-editions/sonarqube-community-edition/) are widely used static analysis solutions for continuous code quality and security inspection.
15+
16+
They help developers detect coding issues in 30+ languages, frameworks, and IaC platforms, including Java, JavaScript, TypeScript, C#, Python, C, C++, and [many more](https://www.sonarsource.com/knowledge/languages/).
817

918
## Requirements
1019

1120
A previous step must have run an analysis on your code.
1221

13-
Read more information on how to analyze your code [here](https://docs.sonarqube.org/latest/analysis/github-integration/)
22+
Read more information on how to analyze your code for SonarQube Server [here](https://docs.sonarsource.com/sonarqube-server/latest/devops-platform-integration/github-integration/introduction/) and for SonarQube Community Build [here](https://docs.sonarsource.com/sonarqube-community-build/devops-platform-integration/github-integration/introduction/)
1423

1524
## Usage
1625

@@ -36,14 +45,14 @@ jobs:
3645
fetch-depth: 0
3746

3847
# Triggering SonarQube analysis as results of it are required by Quality Gate check.
39-
- name: SonarQube Server Scan
48+
- name: SonarQube Scan
4049
uses: sonarsource/sonarqube-scan-action@master
4150
env:
4251
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
4352
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
4453

4554
# Check the Quality Gate status.
46-
- name: SonarQube Server Quality Gate check
55+
- name: SonarQube Quality Gate check
4756
id: sonarqube-quality-gate-check
4857
uses: sonarsource/sonarqube-quality-gate-action@master
4958
with:
@@ -54,13 +63,13 @@ jobs:
5463

5564
# Optionally you can use the output from the Quality Gate in another step.
5665
# The possible outputs of the `quality-gate-status` variable are `PASSED`, `WARN` or `FAILED`.
57-
- name: "Example show SonarQube Server Quality Gate Status value"
66+
- name: "Example show SonarQube Quality Gate Status value"
5867
run: echo "The Quality Gate status is ${{ steps.sonarqube-quality-gate-check.outputs.quality-gate-status }}"
5968
```
6069
6170
Make sure to set up `pollingTimeoutSec` property in your step, to avoid wasting action minutes per month (see above example). If not provided, the default value of 300s is applied.
6271

63-
When using this action with [sonarsource/sonarqube-scan](https://github.com/SonarSource/sonarqube-scan-action) action or with [C/C++ code analysis](https://docs.sonarqube.org/latest/analysis/languages/cfamily/) you don't have to provide `scanMetadataReportFile` input, otherwise you should alter the location of it.
72+
When using this action with [sonarsource/sonarqube-scan](https://github.com/SonarSource/sonarqube-scan-action) action or with [C/C++ code analysis](https://docs.sonarsource.com/sonarqube-server/latest/analyzing-source-code/languages/c-family/overview/) (available only for SonarQube Server) you don't have to provide `scanMetadataReportFile` input, otherwise you should alter the location of it.
6473

6574
Typically, report metadata file for different scanners can vary and can be located in:
6675

@@ -71,19 +80,19 @@ Typically, report metadata file for different scanners can vary and can be locat
7180
Example usage:
7281

7382
```yaml
74-
- name: SonarQube Server Quality Gate check
83+
- name: SonarQube Quality Gate check
7584
uses: sonarsource/sonarqube-quality-gate-action@master
7685
with:
7786
scanMetadataReportFile: target/sonar/report-task.txt
7887
```
7988

8089
### Environment variables
8190

82-
- `SONAR_TOKEN` – **Required** this is the token used to authenticate access to SonarQube Server. You can read more about security tokens [here](https://docs.sonarqube.org/latest/user-guide/user-token/). You can set the `SONAR_TOKEN` environment variable in the "Secrets" settings page of your repository, or you can add them at the level of your GitHub organization (recommended).
91+
- `SONAR_TOKEN` – **Required** this is the token used to authenticate access to SonarQube. You can read more about security tokens [here](https://docs.sonarqube.org/latest/user-guide/user-token/). You can set the `SONAR_TOKEN` environment variable in the "Secrets" settings page of your repository, or you can add them at the level of your GitHub organization (recommended).
8392

84-
- `SONAR_HOST_URL` – **Optional** this tells the scanner where SonarQube Server is hosted, otherwise it will get the one from the scan report. You can set the `SONAR_HOST_URL` environment variable in the "Secrets" settings page of your repository, or you can add them at the level of your GitHub organization (recommended).
93+
- `SONAR_HOST_URL` – **Optional** this tells the scanner where SonarQube is hosted, otherwise it will get the one from the scan report. You can set the `SONAR_HOST_URL` environment variable in the "Secrets" settings page of your repository, or you can add them at the level of your GitHub organization (recommended).
8594

86-
- `SONAR_ROOT_CERT` – Holds an additional root certificate (in PEM format) that is used to validate the SonarQube Server certificate. You can set the `SONAR_ROOT_CERT` environment variable in the "Secrets" settings page of your repository, or you can add them at the level of your GitHub organization (recommended).
95+
- `SONAR_ROOT_CERT` – Holds an additional root certificate (in PEM format) that is used to validate the SonarQube certificate. You can set the `SONAR_ROOT_CERT` environment variable in the "Secrets" settings page of your repository, or you can add them at the level of your GitHub organization (recommended).
8796

8897
## Quality Gate check run
8998

images/SQ_Logo_Community_dark.png

3.91 KB
Loading

images/SQ_Logo_Community_light.png

4.05 KB
Loading

images/SonarQubeServer_dark.png

3.63 KB
Loading
File renamed without changes.

0 commit comments

Comments
 (0)