Table of Contents

Sonar

https://www.sonarqube.org/

Docker

https://hub.docker.com/_/sonarqube/

How to start

docker run -it --name sonarqube -p 9000:9000 -p 9092:9092 sonarqube
docker run -d --name sonarqube -p 9000:9000 -p 9092:9092 sonarqube

Integrate with gradle project

Add to build.gradle

plugins {
  id "org.sonarqube" version "2.6"
}

Then run it for your project

./gradlew sonarqube \
  -Dsonar.host.url=http://127.0.0.1:9000 \
  -Dsonar.login=5562755a8827e8de31011b81eada980cb39ad0e3