From 6f6e4b367dd3e645d50e8092a55b825418bde2c2 Mon Sep 17 00:00:00 2001 From: Stephen Smoogen Date: Tue, 7 Jan 2020 21:52:19 +0000 Subject: [PATCH] nagios_client: An attempt to fix the fedmsg to look for the right gateway name depending on OS release --- .../templates/check_fedmsg_gateway_proc.cfg.j2 | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/roles/nagios_client/templates/check_fedmsg_gateway_proc.cfg.j2 b/roles/nagios_client/templates/check_fedmsg_gateway_proc.cfg.j2 index d6e9774a85..d14b4c1a41 100644 --- a/roles/nagios_client/templates/check_fedmsg_gateway_proc.cfg.j2 +++ b/roles/nagios_client/templates/check_fedmsg_gateway_proc.cfg.j2 @@ -1 +1,11 @@ +{% if ansible_distribution_major_version|int = 7 and ansible_distribution is "RedHat" %} command[check_fedmsg_gateway_proc]={{ libdir }}/nagios/plugins/check_procs -c 1:1 -C 'fedmsg-gateway' -u fedmsg +{% elif ansible_distribution_major_version|int < 30 and ansible_distribution is "Fedora" %} +command[check_fedmsg_gateway_proc]={{ libdir }}/nagios/plugins/check_procs -c 1:1 -C 'fedmsg-gateway' -u fedmsg +{% elif ansible_distribution_major_version|int = 8 and ansible_distribution is "RedHat" %} +command[check_fedmsg_gateway_proc]={{ libdir }}/nagios/plugins/check_procs -c 1:1 -C 'fedmsg-gateway-3' -u fedmsg +{% elif ansible_distribution_major_version|int >= 30 and ansible_distribution is "Fedora" %} +command[check_fedmsg_gateway_proc]={{ libdir }}/nagios/plugins/check_procs -c 1:1 -C 'fedmsg-gateway-3' -u fedmsg +{% else %} +command[check_fedmsg_gateway_proc]={{ libdir }}/nagios/plugins/check_procs -c 1:1 -C 'fedmsg-gateway' -u fedmsg +{% endif %}