Skip to content

Latest commit

 

History

History
23 lines (17 loc) · 1.79 KB

README.md

File metadata and controls

23 lines (17 loc) · 1.79 KB

sonarqube-slack-pusher

Build Status Jenkins plugin for pushing SonarQube projects quality gate status to a given Slack channel.

The plugin runs as a post build action and runs no matter the outcome of the job. The plugin makes an API request to a SonarQube server instance to get the quality status for a given SonarQube project. If the SonarQube project has a quality gate defined the plugin will report to a configured Slack channel if there are any 'failed' quality gate checks.

For a failed quality gate it would look like this:

Notification example from Slack channel

Configuration

Parameter Usage Examples
Slack hook This is the hook into a given channel and it is generated by the Slack incoming Webhook extension. Just paste the full URL here. https://hooks.slack.com/services/12/34/56
Other channel The default channel can be overridden by entering an alternative channel name. 'team-spawn'
SonarQube root URL This is the root of the remote SonarQube installation. The URL is the base for the metrics query and linkage to jobs. sonar.mycompany.com:9000
SonarQube job name The name the project has in SonarQube minus any specific branch post-fix. Case sensitive. 'super-awesome-service'
Branch name The name the project has in SonarQube is usually the job name post-pended with a branch name e.g. 'JobName BranchName'. Case sensitive. 'bugfixBranch'
User name User name if you need to do basic authentication against the SonarQube server. 'username'
User password If you need to authenticate against the SonarQube server. '********'