Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-56515

SonarQube scanner exited with non-zero code: 2

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • sonar-plugin
    • None
    • POC

      We are not able to run the scanner and we are getting below error message.

       
      Started by user
      Jenkins Admin
      Building in workspace /var/jenkins_home/workspace/Sonar_Demo
      No credentials specified
      > git rev-parse --is-inside-work-tree # timeout=10
      Fetching changes from the remote Git repository
      > git config remote.origin.url
      https://github.com/ValaxyTech/SCA.git

      1. timeout=10
        Fetching upstream changes from
        https://github.com/ValaxyTech/SCA.git
        > git --version # timeout=10
        > git fetch --tags --progress
        https://github.com/ValaxyTech/SCA.git
        +refs/heads/:refs/remotes/origin/
        > git rev-parse refs/remotes/origin/master^{commit} # timeout=10
        > git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10
        Checking out Revision d6e7d9beb67239cac2fe5ac6a4d94c2bd8add5ca (refs/remotes/origin/master)
        > git config core.sparsecheckout # timeout=10
        > git checkout -f d6e7d9beb67239cac2fe5ac6a4d94c2bd8add5ca
        Commit message: "Simple customer app parent directory deleted"
        > git rev-list --no-walk d6e7d9beb67239cac2fe5ac6a4d94c2bd8add5ca # timeout=10
        [Sonar_Demo] $ /opt/sonar_scanner/src/main/assembly/bin/sonar-scanner -Dsonar.host.url=
        http://172.20.0.3:9000/sonar
                    • -Dsonar.projectName=ValaxyDemo -Dsonar.projectVersion=1.0 -Dsonar.projectKey=Valaxy -Dsonar.sources=/var/jenkins_home/workspace/Sonar_Demo/SCA/src -Dsonar.projectBaseDir=/var/jenkins_home/workspace/Sonar_Demo
                      /opt/sonar_scanner/src/main/assembly/bin/sonar-scanner: 31: /opt/sonar_scanner/src/main/assembly/bin/sonar-scanner: Bad substitution
                      WARN: Unable to locate 'report-task.txt' in the workspace. Did the SonarScanner succedeed?
                      ERROR: SonarQube scanner exited with non-zero code: 2
                      Finished: FAILURE

            sonarteam Sonar Team
            bharathkumar33 Bharath Kumar
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: