you must define the following mandatory properties for ‘unknown’: sonar.projectkey : If you have this error in jenkins console when you try to use sonar scanner try the next solution :

Error msg: You must define the following mandatory properties for ‘Unknown’: sonar.projectKey

Solution :

projectKey is simply the unique identifier of your project inside SonarQube. You ahave to choose whatever you want, as long as it is unique.

Then try to set the same key into the sonar scanner config :

sonar.projectKey= 8131572732578c67a30dbc6313a681 // this is the created key
sonar.projectVersion=1.0
sonar.projectName=projet_formation
sonar.sources=src/main/java/
sonar.language=java

Commentaires

  1. Pingback: Solution for : Maven not found in Jenkins » JavaTuto

Laisser un commentaire