简体   繁体   中英

C# project in sonarqube

When I run sonar-runner for an analysis my simple C# project the analysis terminate on error on SonarLint.Runner.exe of permission denied:

ERROR: Error during SonarQube Scanner execution
ERROR: java.io.IOException: Cannot run program "/opt/sonarqube-5.4/projects/ArturiCSharpSort/.sonar/SonarLint.Runner/SonarLint.Runner.exe": error=13, Permission denied
ERROR: Caused by: Cannot run program "/opt/sonarqube-5.4/projects/ArturiCSharpSort/.sonar/SonarLint.Runner/SonarLint.Runner.exe": error=13, Permission denied
ERROR: Caused by: error=13, Permission denied

Effectively

-rw-r--r-- 1 root root 19456 Apr  5 11:14 .sonar/Lint.Runner/SonarLint.Runner.exe

This following is my sonar-project.properties:

# Root project information

sonar.projectKey=ArturiCSharpSort

sonar.projectName=ArturiCSharpSort

sonar.projectVersion=1.0

# Some properties that will be inherited by the modules

sonar.sources=.

#List of the module identifiers

#sonar.modules=

# Properties can obviously be overriden for

# each module - just prefix them with the module ID

#module1.sonar.projectName=

#module2.sonar.projectName=

I try to act a chmod on SonarLint.Runner.exe but it is rebuil at every analysis. How can I run analysis on C# project?

Analysis of C# projects must be done on a Windows environment. Here it's failing because the project is analysed on Linux.

The thing is that SonarQube C# Plugin really is targeted to the Windows .NET ecosystem, which is where you'd anyhow build/maintain .NET projects. It must be used with the SonarQube Scanner for MSBuild , which requires MSBuild 14.0.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM