awssonarqube

Understand the default configuration

The SonarQube installation folder is located in /opt/bitnami/apps/sonarqube/, which has the following contents:

Directory Content
conf/ SonarQube’s Apache configuration files.
sonarqube/ SonarQube’s files.
sonarqube/bin/ SonarQube’s binaries.
sonarqube/conf/ SonarQube’s configuration files.
sonarqube/data/ SonarQube’s data.
sonarqube/…
scripts/ Scripts to manage SonarQube’s service.

Analyze your first project with SonarQube Scanner

To get started with the Bitnami SonarQube Stack and SonarQube Scanner, you can follow this two-minute quickstart guide to analyze a sample project:

Linux and Mac OS X

  • Download the SonarQube Scanner zip file. You can find it for all platforms on this link.
  • Unzip it in /opt:

    $ sudo unzip -d /opt sonar-scanner-cli-*.zip
    
  • Download some sample projects from this link.

  • Unzip them in $HOME/sonar-scanning-examples:

    $ unzip -d $HOME master.zip
    
  • Analyze a project as shown below. Replace the USERNAME and PASSWORD placeholders with the correct user name and password.

    $ cd $HOME/sonar-scanning-examples/sonarqube-scanner
    $ /opt/sonar-scanner-*/bin/sonar-scanner -Dsonar.login=USERNAME -Dsonar.password=PASSWORD
    
  • Browse to http://SERVER-IP to find out the results. (SERVER-IP is a placeholder. Please, replace it with the actual domain of your SonarQube server).

Windows

  • Download the SonarQube Scanner zip file. You can find it for all platforms on this link.
  • Unzip it in C:\sonar-scanner.
  • Download some sample projects from this link.
  • Unzip them in %HOMEPATH%\sonar-scanning-examples.
  • Analyze a project as shown below. Replace the USERNAME and PASSWORD placeholders with the correct user name and password.

    $ cd %HOMEPATH%\sonar-scanning-examples\sonarqube-scanner
    $ C:\sonar-scanner\bin\sonar-scanner.bat -D sonar.login=USERNAME -D sonar.password=PASSWORD
    
  • Browse to http://SERVER-IP to find out the results. (SERVER-IP is a placeholder. Please, replace it with the actual domain of your SonarQube server).

You can find more information about SonarQube Scanner at SonarQube’s official documentation.

Last modification August 30, 2018