- New notification script (incidentio-notification.sh) that POSTs JSON
payloads to incident.io HTTP alert sources via curl/jq
- New Icinga2 config template defining User, NotificationCommand (host
+ service), and apply Notification rules — follows the PagerDuty
pattern with opt-in via vars.enable_incidentio
- Notification type mapping: PROBLEM/DOWN/CRITICAL/WARNING/UNKNOWN →
firing, RECOVERY/UP/OK → resolved, ACKNOWLEDGEMENT → firing with
metadata
- Deduplication keys: host-{name} for hosts, service-{host}-{service}
for services
- Deployed via Ansible: script copied to /etc/icinga2/scripts/,
config rendered to conf.d/; gated on icinga2_incidentio_token being
defined
35 lines
1.5 KiB
YAML
35 lines
1.5 KiB
YAML
---
|
|
ansible_host: 204.110.191.241
|
|
ansible_python_interpreter: /usr/bin/python3
|
|
ansible_ssh_common_args: '-o StrictHostKeyChecking=accept-new'
|
|
|
|
firewall_allow_rules:
|
|
- port: 80
|
|
proto: tcp
|
|
comment: HTTP
|
|
- port: 443
|
|
proto: tcp
|
|
comment: HTTPS
|
|
- port: 5665
|
|
proto: tcp
|
|
comment: Icinga2 API
|
|
|
|
# ---- monitor role overrides ----
|
|
icinga2_master_zone_name: master
|
|
# Live install loads conf.d/* host + service definitions.
|
|
icinga2_load_confd: true
|
|
|
|
# Secrets — see roles/monitor/README.md and host_vars/monitor.vntx.net/vault.yml
|
|
icinga2_api_user_root_password: "{{ vault_icinga2_api_user_root_password }}"
|
|
icinga2_api_user_icingaweb2_password: "{{ vault_icinga2_api_user_icingaweb2_password }}"
|
|
icinga2_ido_db_password: "{{ vault_icinga2_ido_db_password }}"
|
|
icingaweb2_db_password: "{{ vault_icingaweb2_db_password }}"
|
|
icingaweb2_ido_db_password: "{{ vault_icingaweb2_ido_db_password }}"
|
|
icinga2_iftraffic_snmp_community: "{{ vault_icinga2_iftraffic_snmp_community }}"
|
|
icinga2_pagerduty_key: "{{ vault_icinga2_pagerduty_key }}"
|
|
icinga2_pagerduty_servers_key: "{{ vault_icinga2_pagerduty_servers_key }}"
|
|
|
|
# incident.io alert integration
|
|
icinga2_incidentio_endpoint_url: "https://api.incident.io/v2/alert_events/http/01KYB0N5Q9ZCB4FABJ4SX2C1Y2"
|
|
icinga2_incidentio_token: "{{ vault_icinga2_incidentio_token }}"
|
|
icingaweb2_admin_password_hash: "{{ vault_icingaweb2_admin_password_hash | default('') }}"
|