Add the SonarQube integration
The integration gives Astrolabe the address of your SonarQube and its token. You do it once, as an administrator.
Before you start: a SonarQube user token, see Create a SonarQube token.
How to
1. Open the SonarQube integration
- In the left sidebar, at the bottom, click Administration.
- Under PLATFORM, click Company connections.
- On the SonarQube card, click Configure.
- Top right, click Add Token.
2. Fill in the form
| Field | What to enter | Example |
|---|---|---|
| Name | A name of your choice | SonarQube |
| SonarQube base URL | The address of SonarQube, with https:// | https://sonar.example.com |
| SonarQube API Key | The token you created |
3. Test and save
- Click Test connection. The form says Connection works: the source accepted the credentials.
- Click Add. Astrolabe restarts on its own, in a few seconds.
The token is in the list, with State set to Connected.
✅ Done. Next: Show SonarQube on a component.
You have several SonarQube
Add one integration per SonarQube, and give each one an instance key.
- Repeat the steps above for each SonarQube.
- In the form, open Optional settings and fill in SonarQube instance key with a short name:
letters, digits,
.,_and-.
| SonarQube | Name | SonarQube instance key |
|---|---|---|
| Production | SonarQube prod | prod |
| Other environments | SonarQube dev | dev |
A component then picks its SonarQube in its annotation: see Show SonarQube on a component.
The default SonarQube
A project key without an instance key is read from the integration whose instance key is
default, otherwise from the first one in the list.