I'm trying to apply part of the pattern from this host dependency example, which appears in the documentation, to services:
apply Dependency "vm-host-to-parent-master" to Host { parent_host_name = host.vars.vm_parent assign where "generic-vm" in host.templates } I'd like to make notifications for any service checks that import the "by_ssh" check dependent on the "ssh" service check succeeding. My attempt looks like this: apply Dependency "by_ssh-to-ssh" to Service { parent_host_name = host.name parent_service_name = "ssh" assign where "by_ssh" in service.templates } I'm not getting an error when Icinga loads this configuration, but I'm also not getting a defined dependency. Running 'icinga2 object list --type dependency' returns nothing. The table at the top of the Config Object Types documentation says that all configuration objects share a "templates" array, but given the above failure it seems like I've either got the wrong object name for services, or the templates array is not implemented for the service object (although I would expect that to throw some sort of error). Can anyone point out what I'm doing wrong here, or is this a bug that needs reporting? I'm using icinga2 r2.10.1-1 from https://packages.icinga.com/debian on Debian stretch. Thanks.
_______________________________________________ icinga-users mailing list icinga-users@lists.icinga.org https://lists.icinga.org/mailman/listinfo/icinga-users