Giter VIP home page Giter VIP logo

sonarqube's Introduction

sonarqube

Installs and configures SonarQube server and the SonarQube Scanner. Provides a LWRP for for installing SonarQube plugins.

Requirements

Platforms

  • CentOS
  • Ubuntu

Tested on:

  • CentOS 6.4
  • Ubuntu 12.04

Dependencies

SonarQube requires JDK 1.7 or later. Use the Java Cookbook to install a suitable Oracle JDK or OpenJDK.

Recipes

default

Installs SonarQube Server and manages sonar.properties.

scanner

Installs SonarQube Scanner and manages sonar-runner.properties. Adds the SonarQube Scanner to all users' PATH via /etc/profile.d.

LWRP

sonarqube_plugin

This LWRP manages SonarQube plugins.

The :install action installs a SonarQube plugin to an existing SonarQube Server instance. Plugins are retrieved from SonarSource's distribution mirror. The plugin version must be specifed.

# Installs version 1.3 of the SonarQube Groovy plugin
sonarqube_plugin 'groovy' do
  version 1.3
end

The :uninstall action removes a SonarQube plugin.

sonarqube_plugin 'groovy' do
  version 1.3
  action :uninstall
end

Usage

SonarQube Server

On systems that should be SonarQube servers, add recipe[sonarqube] to the runlist.

By default, the SonarQube server will connect to an embedded H2 database. To connect to a different database, override:

  • node['sonarqube']['jdbc']['username']
  • node['sonarqube']['jdbc']['password']
  • node['sonarqube']['jdbc']['url']

SonarQube Scanner

On systems that need to invoke SonarQube analyses against an existing SonarQube Server (such as a CI machine), add recipe[sonarqube::scanner] to the runlist.

By default, the SonarQube Scanner will search for a SonarQube server running on localhost:9000. To connect to a different SonarQube Server, override:

  • node['sonarqube']['scanner']['host']['url']

If the SonarQube Server prohibits anonymous users from executing analyses, also override:

  • node['sonarqube']['scanner']['host']['username']
  • node['sonarqube']['scanner']['host']['password']

Advanced Attributes

Browse the attributes directory to view advanced attributes.

Notes

  • Does not run apt::default on Ubuntu
    • add apt::default to your run list before anything else if you need it (e.g. for the Java installation as described in the previous bullet)

Contributing

Prerequisites

chef gem install rubocop

Testing

Test changes using:

chef exec rake
chef exec kitchen verify

Publishing

chef exec knife cookbook site share sonarqube "Monitoring & Trending"

Author

Christian Willman [email protected]

License

MIT

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.