From 54219928e4bb173966587ca8b5ec314aab0ea531 Mon Sep 17 00:00:00 2001 From: Franziska Kunsmann Date: Sun, 22 Nov 2020 11:07:02 +0100 Subject: [PATCH] bundles/icinga2: only add user to on-call group if they have atleast one of (email, phone) set --- bundles/icinga2/files/icinga2/users.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundles/icinga2/files/icinga2/users.conf b/bundles/icinga2/files/icinga2/users.conf index 7e26f68..06441bd 100644 --- a/bundles/icinga2/files/icinga2/users.conf +++ b/bundles/icinga2/files/icinga2/users.conf @@ -10,7 +10,7 @@ object User "${username}" { states = [ OK, Warning, Critical, Up, Down ] types = [ Problem, Recovery ] -% if config['is_admin']: +% if config['is_admin'] and (config['email'] or config['phone']): groups = [ "on-call_sms" ] % endif