Skip to content

catcherwong/dotnet-sonarscanner-with-docker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

dotnet-sonarscanner-with-docker

dotnet-sonarscanner-with-docker is a Dockerfile that helps to run .NET Core project with SonarQube.

It provider an easy way to run sonar scanner for dotnet project with docker, you do not need to install JDK and dotnet SDK on your machine.

This repository is inspired by docker-dotnet-sonarscanner.

How to build

docker build -t dotnet-scanner:v202302 .

How to use

docker run --name dotnet-scanner -it --rm \
    -v PUT_YOUR_PROJECT_DIR_HERE:/project/src \
    -e PROJECT_KEY=PUT_YOUR_PROJECT_KEY_HERE \
    -e PROJECT_PATH=/project/src/PUT_YOUR_PROJECT_PATH_HERE \
    -e HOST=PUT_YOUR_HOST_HERE \
    -e LOGIN_KEY=PUT_YOUR_KEY_HERE \
    dotnet-scanner:v202302

NOTE:

  1. If you have a private NuGet feed, please update nuget.config;
  2. The Dockerfile includes dotnet sdk 3.1 and 6.0 by default;

More Information

Blogs

https://www.cnblogs.com/catcher1994/p/17180511.html

Execute Step

Result

About

An easy way to run sonar scanner for dotnet project with docker.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published