diff --git a/roles/monitoring-master/files/services_vhosts_http_checks.conf b/roles/monitoring-master/files/services_vhosts_http_checks.conf new file mode 100644 index 0000000..a109e07 --- /dev/null +++ b/roles/monitoring-master/files/services_vhosts_http_checks.conf @@ -0,0 +1,7 @@ +apply Service for (http_vhost => config in host.vars.http_vhosts) { + import "generic-service" + + check_command = "http" + + vars += config +} diff --git a/roles/monitoring-master/tasks/main.yaml b/roles/monitoring-master/tasks/main.yaml index 917ee7d..3c018a2 100644 --- a/roles/monitoring-master/tasks/main.yaml +++ b/roles/monitoring-master/tasks/main.yaml @@ -79,6 +79,7 @@ mode: 0640 with_items: - icinga_master_hosts.conf + - services_vhosts_http_checks.conf - services_passive.conf - services_passive_mail_extern.conf - services_async.conf