GitLab
Configure GitLab for Radar
GitLab uses access tokens instead of an app model. Works with both gitlab.com and self-hosted instances.
Create an access token
Go to your Project (or Group) > Settings > Access Tokens.
Create a new token:
- Name:
Radar Security - Role: Developer or higher
- Scopes:
api
Copy the token (starts with glpat-).
Configure the webhook
Go to Settings > Webhooks in your project or group and add a new webhook:
| Field | Value |
|---|---|
| URL | https://your-domain.com/gitlab/webhook |
| Secret token | Generate one: openssl rand -hex 32 |
| Trigger | Merge request events |
| SSL verification | Enable (recommended) |
Environment variables
GITLAB_ACCESS_TOKEN=glpat-xxxxxxxxxxxxxxxxxxxx
GITLAB_WEBHOOK_SECRET=your-webhook-secretThe GitLab instance URL is automatically detected from the webhook payload, so self-hosted instances work without extra configuration.