mirror of
https://github.com/SonarSource/sonarqube-scan-action.git
synced 2025-12-15 18:46:31 +00:00
docs(readme): utilise GitHub variables for non sensitive data
This commit is contained in:
parent
1b9d398800
commit
efe7928173
1 changed files with 6 additions and 6 deletions
12
README.md
12
README.md
|
|
@ -51,7 +51,7 @@ jobs:
|
|||
uses: sonarsource/sonarqube-scan-action@master
|
||||
env:
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
|
||||
SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }}
|
||||
```
|
||||
|
||||
If your source code file names contain special characters that are not covered by the locale range of `en_US.UTF-8`, you can configure your desired locale like this:
|
||||
|
|
@ -61,7 +61,7 @@ If your source code file names contain special characters that are not covered b
|
|||
uses: sonarsource/sonarqube-scan-action@master
|
||||
env:
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
|
||||
SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }}
|
||||
LC_ALL: "ru_RU.UTF-8"
|
||||
```
|
||||
|
||||
|
|
@ -72,7 +72,7 @@ If your SonarQube server uses a self-signed certificate, you can pass a root cer
|
|||
uses: sonarsource/sonarqube-scan-action@master
|
||||
env:
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
|
||||
SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }}
|
||||
SONAR_ROOT_CERT: ${{ secrets.SONAR_ROOT_CERT }}
|
||||
```
|
||||
|
||||
|
|
@ -102,9 +102,9 @@ More information about possible analysis parameters can be found in [the documen
|
|||
|
||||
### Environment variables
|
||||
|
||||
- `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).
|
||||
- `SONAR_HOST_URL` – **Required** this tells the scanner where SonarQube is hosted. 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).
|
||||
- `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).
|
||||
- `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` in the "Secrets and variables" settings page as secret of your repository, or you can add them at the level of your GitHub organization (recommended).
|
||||
- `SONAR_HOST_URL` – **Required** this tells the scanner where SonarQube is hosted. You can set the `SONAR_HOST_URL` in the "Secrets and variables" settings page as variable of your repository, or you can add them at the level of your GitHub organization (recommended).
|
||||
- `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` in the "Secrets and variables" settings page as secret of your repository, or you can add them at the level of your GitHub organization (recommended).
|
||||
|
||||
## Alternatives for Java, .NET, and C/C++ projects
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue