From f8e01ef3c5cc725a685f03869d8d821176181baa Mon Sep 17 00:00:00 2001 From: elijah Date: Tue, 25 Feb 2014 12:04:39 -0800 Subject: new monitor hosts rule: local environment monitors just see local machines, other monitors see the nodes from all environments (except local) --- provider_base/services/monitor.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'provider_base/services/monitor.json') diff --git a/provider_base/services/monitor.json b/provider_base/services/monitor.json index 82c18745..03f6c6d1 100644 --- a/provider_base/services/monitor.json +++ b/provider_base/services/monitor.json @@ -1,9 +1,9 @@ { "nagios": { "nagiosadmin_pw": "= secret :nagios_admin_password", - "hosts": "= nodes_like_me.pick_fields('domain.internal', 'ip_address', 'services', 'openvpn.gateway_address')" + "hosts": "= (self.environment == 'local' ? nodes_like_me : nodes[:environment => '!local']).pick_fields('domain.internal', 'domain.full_suffix', 'ip_address', 'services', 'openvpn.gateway_address', 'ssh.port')" }, - "hosts": "= hosts_file(nodes_like_me)", + "hosts": "= self.environment == 'local' ? hosts_file(nodes_like_me) : hosts_file(nodes[:environment => '!local'])", "ssh": { "monitor": { "username": "= Leap::Platform.monitor_username", -- cgit v1.2.3