Skip to content

Instantly share code, notes, and snippets.

Volker Janzen frootmig

Block or report user

Report or block frootmig

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View icinga-services.conf.j2
// This file has been created by Ansible
object Service "disk" {
import "generic-service"
check_command = "disk"
host_name = "{{ hostitem }}"
}
View zones.conf.j2
object Zone "global-templates" {
global = true
}
object Endpoint "{{ master_hostname }}" {
host = "{{ master_hostname }}"
}
object Zone "{{ master_hostname }}" {
endpoints = [ "{{ master_hostname }}" ]
View icinga-host.conf.j2
object Host "{{ hostitem }}" {
import "generic-host"
check_command = "hostalive"
address = "{{ hostvars[hostitem]['icinga_addr'] }}"
address6 = "{{ hostvars[hostitem]['icinga_addr6'] }}"
vars.os = "Linux"
zone = "MASTERFQDN"
}
@frootmig
frootmig / deploy-icinga-agent.yml
Created Mar 25, 2017
Deploy Icinga 2 satellite and add it to master
View deploy-icinga-agent.yml
---
#
# Setting up the Icinga2 PKI is derived from https://monitoring-portal.org/index.php?thread/35989-using-ansible-to-generate-the-icinga-client-certificates/
#
- hosts: MASTERFQDN
tasks:
- name: generate ticket on the icinga master and save it as a variable
shell: /usr/sbin/icinga2 pki ticket --cn {{ hostitem }}
register: ticket
- hosts: "{{ hostitem }}"
You can’t perform that action at this time.