bchsonarqube

Install plugins

NOTE: We are in the process of modifying the file structure and configuration for many Bitnami stacks. On account of these changes, the file paths stated in this guide may change depending on whether your Bitnami stack uses native Linux system packages (Approach A), or if it is a self-contained installation (Approach B). To identify your Bitnami installation type and what approach to follow, run the command below:

 $ test ! -f "/opt/bitnami/common/bin/openssl" && echo "Approach A: Using system packages." || echo "Approach B: Self-contained installation."

The output of the command indicates which approach (A or B) is used by the installation, and will allow you to identify the paths, configuration and commands to use in this guide. Refer to the FAQ for more information on these changes.

The Bitnami SonarQube Stack includes the plugins below by default:

Install plugins from the Admin Dashboard

You can install plugins from the Admin Dashboard. To install a new plugin in SonarQube, follow these steps:

  • Log in to the SonarQube dashboard and click on the “Administration” tab.
  • Under the “System” dropdown menu, click on “Update center”.
  • Select the “Available” tab and look for the plugin you want to install.
  • Click on the “Install” button.
  • Once the process finishes, you will be prompted to restart SonarQube in order to complete the installation. Click on the “Restart” button.
  • You will be prompted to confirm the action. Click again on the “Restart” button. This could take a few minutes.
  • That’s it! Now you can navigate to the “Update center” again and check that your plugin is installed.

Manually install plugins

To install a SonarQube plugin, download the plugin (.jar file) and save it in the SonarQube plugins directory. Then, change the file ownership to sonarqube user.

Here is an example of installing the GitHub plugin for SonarQube:

  • Log in to the server console.

  • Navigate to the SonarQube plugins directory. Depending on your installation type, execute the following command:

    • Approach A (Bitnami installations using system packages):

        $ cd /opt/bitnami/sonarqube/extensions/plugins
      
    • Approach B (Self-contained Bitnami installations):

        $ cd /opt/bitnami/sonarqube/extensions/plugins
      
  • Download the latest version of the plugin JAR by running the command below:

      $ sudo wget https://sonarsource.bintray.com/Distribution/sonar-github-plugin/sonar-github-plugin-X.Y.Z.jar
    
    • Change the ownership.

        $ sudo chown -R sonarqube:sonarqube sonar-github-plugin-X.Y.Z.jar
      
    • Restart SonarQube using the command-line script:

        $ sudo /opt/bitnami/ctlscript.sh restart sonarqube
      
Last modification July 14, 2021