Analysis configuration file could not be found 'SonarQubeAnalysisConfig.xml'

Must-share information (formatted with Markdown):

  • Soarqube: Community
  • Docker on localhost
  • Integrate github actions with locally running sonarqube community edition
  • what have you tried so far to achieve this
  • Run sonarqube: community edition on localhost
  • Setup Github App
  • Setup secrets for Token and Host_Url

Following is the sonarqube generated yaml for the github workflow

name: Build

on:
  push:
    branches:
      - master


jobs:
  build:
    name: Build
    runs-on: windows-latest
    steps:
      - uses: actions/checkout@v2
        with:
          fetch-depth: 0  # Shallow clones should be disabled for a better relevancy of analysis
      - name: Set up JDK 11
        uses: actions/setup-java@v1
        with:
          java-version: 1.11
      - name: Cache SonarQube packages
        uses: actions/cache@v1
        with:
          path: ~\sonar\cache
          key: ${{ runner.os }}-sonar
          restore-keys: ${{ runner.os }}-sonar
      - name: Cache SonarQube scanner
        id: cache-sonar-scanner
        uses: actions/cache@v1
        with:
          path: .\.sonar\scanner
          key: ${{ runner.os }}-sonar-scanner
          restore-keys: ${{ runner.os }}-sonar-scanner
      - name: Install SonarQube scanner
        if: steps.cache-sonar-scanner.outputs.cache-hit != 'true'
        shell: powershell
        run: |
          New-Item -Path .\.sonar\scanner -ItemType Directory
          dotnet tool update dotnet-sonarscanner --tool-path .\.sonar\scanner
      - name: Build and analyze
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}  # Needed to get PR information, if any
        shell: powershell
        run: |
          .\.sonar\scanner\dotnet-sonarscanner begin /k:"myorg_WebGoat.NET_key" /d:sonar.token="${{ secrets.SONAR_TOKEN }}" /d:sonar.host.url="${{ secrets.SONAR_HOST_URL }}"
          dotnet build WebGoat.NET.sln
          .\.sonar\scanner\dotnet-sonarscanner end /d:sonar.token="${{ secrets.SONAR_TOKEN }}"

Build and analysis error I get

Run .\.sonar\scanner\dotnet-sonarscanner begin /k:"myorg_WebGoat.NET_key" /d:sonar.token="***" /d:sonar.host.url="***"
  .\.sonar\scanner\dotnet-sonarscanner begin /k:"myorg_WebGoat.NET_key" /d:sonar.token="***" /d:sonar.host.url="***"
  dotnet build WebGoat.NET.sln
  .\.sonar\scanner\dotnet-sonarscanner end /d:sonar.token="***"
  shell: C:\Windows\System32\WindowsPowerShell\v1.0\powershell.EXE -command ". '{0}'"
  env:
    JAVA_HOME_11.0.19_x64: C:\hostedtoolcache\windows\jdk\11.0.19\x64
    JAVA_HOME: C:\hostedtoolcache\windows\jdk\11.0.19\x64
    JAVA_HOME_11_0_19_X64: C:\hostedtoolcache\windows\jdk\11.0.19\x64
    GITHUB_TOKEN: ***
Unhandled exception. System.ArgumentException: username cannot contain the ':' character due to basic authentication limitations
   at SonarScanner.MSBuild.PreProcessor.WebClientDownloaderBuilder.AddAuthorization(String userName, String password)
   at SonarScanner.MSBuild.PreProcessor.PreprocessorObjectFactory.CreateSonarWebServer(ProcessedArgs args, IDownloader downloader)
   at SonarScanner.MSBuild.PreProcessor.PreProcessor.DoExecute(ProcessedArgs localSettings)
   at SonarScanner.MSBuild.PreProcessor.PreProcessor.Execute(IEnumerable`1 args)
   at SonarScanner.MSBuild.BootstrapperClass.PreProcess()
   at SonarScanner.MSBuild.BootstrapperClass.Execute()
   at SonarScanner.MSBuild.Program.Execute(String[] args, ILogger logger)
   at SonarScanner.MSBuild.Program.Execute(String[] args)
   at SonarScanner.MSBuild.Program.Main(String[] args)
   at SonarScanner.MSBuild.Program.<Main>(String[] args)
SonarScanner for MSBuild 5.13
Using the .NET Core version of the Scanner for MSBuild
Pre-processing started.
Preparing working directories...
12:15:55.063  Updating build integration targets...
MSBuild version 17.6.3+07e294721 for .NET
  Determining projects to restore...
  Restored D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj (in 1.33 min).
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(32,43): warning CS8620: Argument of type 'Dictionary<string, string>' cannot be used for parameter 'initialData' of type 'IEnumerable<KeyValuePair<string, string?>>' in 'IConfigurationBuilder MemoryConfigurationBuilderExtensions.AddInMemoryCollection(IConfigurationBuilder configurationBuilder, IEnumerable<KeyValuePair<string, string?>>? initialData)' due to differences in the nullability of reference types. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(66,35): warning CS8604: Possible null reference argument for parameter 'connectionString' in 'DbContextOptionsBuilder SqliteDbContextOptionsBuilderExtensions.UseSqlite(DbContextOptionsBuilder optionsBuilder, string connectionString, Action<SqliteDbContextOptionsBuilder>? sqliteOptionsAction = null)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(159,17): warning CS0219: The variable 'c' is assigned but its value is never used [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\HomeController.cs(39,33): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(31,29): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(25,16): warning CS8618: Non-nullable field '_resourcePath' must contain a non-null value when exiting constructor. Consider declaring the field as nullable. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Data\NorthwindContext.cs(19,47): warning CS8604: Possible null reference argument for parameter 'path1' in 'string Path.Combine(string path1, string path2)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(225,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(240,28): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(117,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(129,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(151,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(183,69): warning CS8604: Possible null reference argument for parameter 'user' in 'Task<IdentityResult> UserManager<IdentityUser>.ChangePasswordAsync(IdentityUser user, string currentPassword, string newPassword)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
  WebGoat.NET -> D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\bin\Debug\net7.0\WebGoat.NET.dll

Build succeeded.

D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(32,43): warning CS8620: Argument of type 'Dictionary<string, string>' cannot be used for parameter 'initialData' of type 'IEnumerable<KeyValuePair<string, string?>>' in 'IConfigurationBuilder MemoryConfigurationBuilderExtensions.AddInMemoryCollection(IConfigurationBuilder configurationBuilder, IEnumerable<KeyValuePair<string, string?>>? initialData)' due to differences in the nullability of reference types. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(66,35): warning CS8604: Possible null reference argument for parameter 'connectionString' in 'DbContextOptionsBuilder SqliteDbContextOptionsBuilderExtensions.UseSqlite(DbContextOptionsBuilder optionsBuilder, string connectionString, Action<SqliteDbContextOptionsBuilder>? sqliteOptionsAction = null)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(159,17): warning CS0219: The variable 'c' is assigned but its value is never used [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\HomeController.cs(39,33): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(31,29): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(25,16): warning CS8618: Non-nullable field '_resourcePath' must contain a non-null value when exiting constructor. Consider declaring the field as nullable. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Data\NorthwindContext.cs(19,47): warning CS8604: Possible null reference argument for parameter 'path1' in 'string Path.Combine(string path1, string path2)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(225,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(240,28): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(117,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(129,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(151,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(183,69): warning CS8604: Possible null reference argument for parameter 'user' in 'Task<IdentityResult> UserManager<IdentityUser>.ChangePasswordAsync(IdentityUser user, string currentPassword, string newPassword)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
    13 Warning(s)
    0 Error(s)

Time Elapsed 00:02:13.44
SonarScanner for MSBuild 5.13
Using the .NET Core version of the Scanner for MSBuild
Post-processing started.
12:18:14.415  SonarQube analysis could not be completed because the analysis configuration file could not be found: D:\a\WebGoat.NET\WebGoat.NET\.sonarqube\conf\SonarQubeAnalysisConfig.xml.
12:18:14.415  Post-processing failed. Exit code: 1
Error: Process completed with exit code 1.

Hey there

This tells me the token provided to SONAR_TOKEN might be corrupt. Did you copy it exactly from the UI, and can you try generating a new token?

Thanks,
That exception was fixed by restoring the token again.
But I’m still facing the below error:

SonarQube analysis could not be completed because the analysis configuration file could not be found: D:\a\WebGoat.NET\WebGoat.NET\.sonarqube\conf\SonarQubeAnalysisConfig.xml.

Appreciate any advice on this.

Regards,

I suggest sharing the full logs, as before

Hi there,

Please see the full log:

Run .\.sonar\scanner\dotnet-sonarscanner begin /k:"senal_WebGoat.NET_key" /d:sonar.token="***" /d:sonar.host.url="***"
  .\.sonar\scanner\dotnet-sonarscanner begin /k:"senal_WebGoat.NET_key" /d:sonar.token="***" /d:sonar.host.url="***"
  dotnet build WebGoat.NET.sln
  .\.sonar\scanner\dotnet-sonarscanner end /d:sonar.token="***"
  shell: C:\Windows\System32\WindowsPowerShell\v1.0\powershell.EXE -command ". '{0}'"
  env:
    JAVA_HOME_11.0.19_x64: C:\hostedtoolcache\windows\jdk\11.0.19\x64
    JAVA_HOME: C:\hostedtoolcache\windows\jdk\11.0.19\x64
    JAVA_HOME_11_0_19_X64: C:\hostedtoolcache\windows\jdk\11.0.19\x64
    GITHUB_TOKEN: ***
SonarScanner for MSBuild 5.13
Using the .NET Core version of the Scanner for MSBuild
Pre-processing started.
Preparing working directories...
09:49:05.904  Updating build integration targets...
09:49:10.108  Unable to connect to server. Please check if the server is running and if the address is correct. Url: '***api/server/version'.
09:49:10.15  An error occured while querying the server version! Please check if the server is running and if the address is correct.
09:49:10.152  Pre-processing failed. Exit code: 1
MSBuild version 17.6.3+07e294721 for .NET
  Determining projects to restore...
  Restored D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj (in 1.27 min).
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\HomeController.cs(39,33): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(31,29): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(25,16): warning CS8618: Non-nullable field '_resourcePath' must contain a non-null value when exiting constructor. Consider declaring the field as nullable. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(225,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(240,28): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(117,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(129,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(151,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(183,69): warning CS8604: Possible null reference argument for parameter 'user' in 'Task<IdentityResult> UserManager<IdentityUser>.ChangePasswordAsync(IdentityUser user, string currentPassword, string newPassword)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(32,43): warning CS8620: Argument of type 'Dictionary<string, string>' cannot be used for parameter 'initialData' of type 'IEnumerable<KeyValuePair<string, string?>>' in 'IConfigurationBuilder MemoryConfigurationBuilderExtensions.AddInMemoryCollection(IConfigurationBuilder configurationBuilder, IEnumerable<KeyValuePair<string, string?>>? initialData)' due to differences in the nullability of reference types. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(66,35): warning CS8604: Possible null reference argument for parameter 'connectionString' in 'DbContextOptionsBuilder SqliteDbContextOptionsBuilderExtensions.UseSqlite(DbContextOptionsBuilder optionsBuilder, string connectionString, Action<SqliteDbContextOptionsBuilder>? sqliteOptionsAction = null)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(159,17): warning CS0219: The variable 'c' is assigned but its value is never used [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Data\NorthwindContext.cs(19,47): warning CS8604: Possible null reference argument for parameter 'path1' in 'string Path.Combine(string path1, string path2)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
  WebGoat.NET -> D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\bin\Debug\net7.0\WebGoat.NET.dll

Build succeeded.

D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\HomeController.cs(39,33): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(31,29): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(25,16): warning CS8618: Non-nullable field '_resourcePath' must contain a non-null value when exiting constructor. Consider declaring the field as nullable. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(225,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\CheckoutController.cs(240,28): warning CS8601: Possible null reference assignment. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(117,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(129,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(151,70): warning CS8604: Possible null reference argument for parameter 'username' in 'Customer? CustomerRepository.GetCustomerByUsername(string username)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Controllers\AccountController.cs(183,69): warning CS8604: Possible null reference argument for parameter 'user' in 'Task<IdentityResult> UserManager<IdentityUser>.ChangePasswordAsync(IdentityUser user, string currentPassword, string newPassword)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(32,43): warning CS8620: Argument of type 'Dictionary<string, string>' cannot be used for parameter 'initialData' of type 'IEnumerable<KeyValuePair<string, string?>>' in 'IConfigurationBuilder MemoryConfigurationBuilderExtensions.AddInMemoryCollection(IConfigurationBuilder configurationBuilder, IEnumerable<KeyValuePair<string, string?>>? initialData)' due to differences in the nullability of reference types. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(66,35): warning CS8604: Possible null reference argument for parameter 'connectionString' in 'DbContextOptionsBuilder SqliteDbContextOptionsBuilderExtensions.UseSqlite(DbContextOptionsBuilder optionsBuilder, string connectionString, Action<SqliteDbContextOptionsBuilder>? sqliteOptionsAction = null)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Startup.cs(159,17): warning CS0219: The variable 'c' is assigned but its value is never used [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\Data\NorthwindContext.cs(19,47): warning CS8604: Possible null reference argument for parameter 'path1' in 'string Path.Combine(string path1, string path2)'. [D:\a\WebGoat.NET\WebGoat.NET\WebGoat.NET\WebGoat.NET.csproj]
    13 Warning(s)
    0 Error(s)

Time Elapsed 00:02:22.01
09:51:32.75  SonarQube analysis could not be completed because the analysis configuration file could not be found: D:\a\WebGoat.NET\WebGoat.NET\.sonarqube\conf\SonarQubeAnalysisConfig.xml.
09:51:32.75  Post-processing failed. Exit code: 1
SonarScanner for MSBuild 5.13
Using the .NET Core version of the Scanner for MSBuild
Post-processing started.
Error: Process completed with exit code 1.

And this is the latest issue.

Are you using a self-hosted GitHub runner with access to your localhost, or trying to use a hosted GitHub runner?

Hi there,
I’m not sure whether I understood self-hosted or hosted GitHub runner. Would you be able to help me setingup the environment?
Basically, my repositories are hosted in GitHub and I’m running the Sonarqube (community version on my local).
I have setup a GitHub App for the communication in between GitHub and my locally running Sonarqube (using docker).
Perhaps I have missed something in the configuration.
I really appreciate your support in this regard.

GitHub Actions is going to need to be able to get in touch with your SonarQube sever. This usually means that it’s hosted on the internet, rather than your local machine (unless your GitHub Actions runner is also hosted locally).

Thank you very much for your feedback.
I’ll try with the GitHub runner hosted locally.

Will keep you posted.