Giter Club home page Giter Club logo

ansible-role-icinga2's Introduction

ansible-role-icinga2

Build Status

Install icinga2 on rhel or debian. Configure agent or master mode and control icinga2 features.

Role Variables

Available variables are listed below, along with default values (see defaults/main.yml):

icinga2 settings

icinga2_role: agent

Choose a role for icinga2. agent or master is possible.

icinga2_ca_host: false

Without a icinga2 server's fqdn this module will fail

icinga2_features: [ "checker", "api", "mainlog" ]

All features in this array will be enabled

icinga2_state: present

Update or not? icinga2_state can be installed,latest,removed,absent,present,build-dep

icinga2 constants

icinga2_PluginDir: /usr/lib64/nagios/plugins
icinga2_ManubulonPluginDir: {{icinga2_PluginDir}}
icinga2_PluginContribDir: {{icinga2_PluginDir}}
icinga2_nodename: {{hostvars[inventory_hostname]['ansible_fqdn'}}
icinga2_ZoneName: master
icinga2_ticketsalt: ...

Manage package repos

icinga2_manage_repo_icinga: true

True for icinga2 community repos, False for distro packages

icinga2_manage_repo_epel: true

True to ensure epel-release rpm is installed.

includes geerlingguy.mysql

icinga2_manage_mysql: false

If you choose true this module will install and configure mysql

ido vars

icinga2_ido_user: icinga
icinga2_ido_password: icinga
icinga2_ido_dbname: icinga
icinga2_ido_host: "127.0.0.1"
icinga2_ido_port: 3306

IDO connection options

All other features

ic2_f_debuglog_options:
  severity: "\"debug\""
  path: "LocalStateDir + \"/log/icinga2/debug.log\""

There is a variable for each feature If you want to change a value, you have to configure all attributes of that feature. All other features work in a similar way.

Dependencies

Example Playbook

You can find an example playbook for testing purposes on https://github.com/chrnie/icinga2-vagrant-ansible.

- hosts: all
  roles:
    - chrnie.icinga2

Tags are supported:

  • ansible-playbook --tags foo --skip-tags bar
  • valid tags: config feature feature_switch install update
  • caused by ansible issue #32015 we have to use the untagged tag.
    • if you only want to update icinga2 on icinga2_master
      • $ ansible-playbook -i hosts/testing 003_icinga2.yml --tags update,untagged --limit icinga2_master --extra-vars "icinga2_state=latest"
    • if you want to enable/disabled configured features on all nodes
      • $ ansible-playbook -i hosts/testing 003_icinga2.yml --tags feature_switch,untagged

License

Apache License 2.0

Author Information

Created in 2017 by Christoph Niemann, https://github.com/chrnie

Forked from https://github.com/mkayontour/icinga2-ansible+

ansible-role-icinga2's People

Contributors

chrnie avatar nguyen26052004 avatar apsivam avatar obscurerichard avatar

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.