<commit_before>[![Build Status](https://travis-ci.org/Icinga/puppet-icinga2.svg?branch=master)](https://travis-ci.org/Icinga/puppet-icinga2)

# Icinga 2 Puppet Module

![Icinga Logo](https://www.icinga.com/wp-content/uploads/2014/06/icinga_logo.png)

#### Table of Contents

1. [Overview][Overview]
2. [Module Description - What the module does and why it is useful][Module description]
3. [Setup - The basics of getting started with icinga2][Setup]
    * [What Icinga 2 affects][]
4. [Usage - Configuration options and additional functionality][Usage]
5. [Reference - An under-the-hood peek at what the module is doing and how][Reference]
    * [Public Classes][]
    * [Private Classes][]
    * [Public defined types][]
    * [Private defined types][]
6. [Development - Guide for contributing to the module][Development]

## Overview

Icinga 2 is a widely used open source monitoring software. This Puppet module helps with installing and managing
configuration of Icinga 2 on multiple operating systems.

## Module Description

This module installs and configures Icinga 2 on your Linux or Windows hosts.

By default it uses packages provided by your distribution's repository or
[Chocolatey] on Windows.

The module can also be configured to use [packages.icinga.com] as the primary repository, which enables you to install
Icinga 2 versions that are newer than the ones provided by your distribution's vendor. All features and objects
available in Icinga 2 can be enabled and configured with this module.

## Setup

### What the Icinga 2 Puppet module supports

* Installation of packages
* Configuration of features
* Configuration of objects (also apply rules)
* Service
* MySQL / PostgreSQL Database Schema Import
* Repository Management
* Certification Authority

### Dependencies

This module depends on:

* [puppetlabs/stdlib] >= 4.10.0
* [puppetlabs/concat] >= 2.0.1

Depending on your setup following modules may also be required:

* [puppetlabs/apt] >= 2.0.0
* [puppetlabs/chocolatey] >= 0.7.0
* [puppet/zypprepo] >= 2.0.0

### Limitations

This module has been tested on:

* Ruby >= 1.9
* Debian 7, 8
* Ubuntu 14.04, 16.04
* CentOS/RHEL 6, 7
    * **Caution:** CentOS 6 comes with Ruby 1.8.7 by default
* OracleLinux 7
* FreeBSD 10, 11
* SLES 12
* Windows Server 2012

Other operating systems or versions may work but have not been tested.

It's recommended to enable the future parser when using this module in combination with exported resources.

## Usage

### Installing Icinga 2

The default class `icinga2` installs and configures a basic installation of Icinga 2. The features `checker`, `mainlog`
and `notification` are enabled by default.

By default, your distribution's packages are used to install Icinga 2. On Windows systems we use the [Chocolatey]
package manager.

Use the `manage_repo` parameter to configure the official [packages.icinga.com] repositories.

``` puppet
class { '::icinga2':
  manage_repo => true,
}
```

If you want to manage the version of Icinga 2, you have to disable the package management of this module and handle
packages in your own Puppet code.

``` puppet
package { 'icinga2':
  ensure => latest,
  notifiy => Class['icinga2'],
}

class { '::icinga2':
  manage_package => false,
}
```

Be careful with this option: Setting `manage_package` to false means that this module will not install any package at
all, including IDO packages.

### Enabling Features

There are two options how you can enable features:
<commit_msg>README.md: fix typo `notifiy`<commit_after>[![Build Status](https://travis-ci.org/Icinga/puppet-icinga2.svg?branch=master)](https://travis-ci.org/Icinga/puppet-icinga2)

# Icinga 2 Puppet Module

![Icinga Logo](https://www.icinga.com/wp-content/uploads/2014/06/icinga_logo.png)

#### Table of Contents

1. [Overview][Overview]
2. [Module Description - What the module does and why it is useful][Module description]
3. [Setup - The basics of getting started with icinga2][Setup]
    * [What Icinga 2 affects][]
4. [Usage - Configuration options and additional functionality][Usage]
5. [Reference - An under-the-hood peek at what the module is doing and how][Reference]
    * [Public Classes][]
    * [Private Classes][]
    * [Public defined types][]
    * [Private defined types][]
6. [Development - Guide for contributing to the module][Development]

## Overview

Icinga 2 is a widely used open source monitoring software. This Puppet module helps with installing and managing
configuration of Icinga 2 on multiple operating systems.

## Module Description

This module installs and configures Icinga 2 on your Linux or Windows hosts.

By default it uses packages provided by your distribution's repository or
[Chocolatey] on Windows.

The module can also be configured to use [packages.icinga.com] as the primary repository, which enables you to install
Icinga 2 versions that are newer than the ones provided by your distribution's vendor. All features and objects
available in Icinga 2 can be enabled and configured with this module.

## Setup

### What the Icinga 2 Puppet module supports

* Installation of packages
* Configuration of features
* Configuration of objects (also apply rules)
* Service
* MySQL / PostgreSQL Database Schema Import
* Repository Management
* Certification Authority

### Dependencies

This module depends on:

* [puppetlabs/stdlib] >= 4.10.0
* [puppetlabs/concat] >= 2.0.1

Depending on your setup following modules may also be required:

* [puppetlabs/apt] >= 2.0.0
* [puppetlabs/chocolatey] >= 0.7.0
* [puppet/zypprepo] >= 2.0.0

### Limitations

This module has been tested on:

* Ruby >= 1.9
* Debian 7, 8
* Ubuntu 14.04, 16.04
* CentOS/RHEL 6, 7
    * **Caution:** CentOS 6 comes with Ruby 1.8.7 by default
* OracleLinux 7
* FreeBSD 10, 11
* SLES 12
* Windows Server 2012

Other operating systems or versions may work but have not been tested.

It's recommended to enable the future parser when using this module in combination with exported resources.

## Usage

### Installing Icinga 2

The default class `icinga2` installs and configures a basic installation of Icinga 2. The features `checker`, `mainlog`
and `notification` are enabled by default.

By default, your distribution's packages are used to install Icinga 2. On Windows systems we use the [Chocolatey]
package manager.

Use the `manage_repo` parameter to configure the official [packages.icinga.com] repositories.

``` puppet
class { '::icinga2':
  manage_repo => true,
}
```

If you want to manage the version of Icinga 2, you have to disable the package management of this module and handle
packages in your own Puppet code.

``` puppet
package { 'icinga2':
  ensure => latest,
  notify => Class['icinga2'],
}

class { '::icinga2':
  manage_package => false,
}
```

Be careful with this option: Setting `manage_package` to false means that this module will not install any package at
all, including IDO packages.

### Enabling Features

There are two options how you can enable features:

{'fraction_non_alphanumeric': 0.09063530761508676, 'fraction_numerical': 0.022085185716334433, 'mean_word_length': 4.377023901310717, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 23, 'https://': 6, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3238206', 'n_tokens_mistral': 2197, 'n_tokens_neox': 2016, 'n_words': 875}