[icinga-checkins] icinga.org: icinga-core/feature/exclude-with-regexp-3720: tests: icinga2 conversion: notification_options, custom attributes, etc

git at icinga.org git at icinga.org
Sat Jul 20 13:54:44 CEST 2013


Module: icinga-core
Branch: feature/exclude-with-regexp-3720
Commit: 8b743cc8d39bb3136b2da60279ff73bdb1be17be
URL:    https://git.icinga.org/?p=icinga-core.git;a=commit;h=8b743cc8d39bb3136b2da60279ff73bdb1be17be

Author: Michael Friedrich <michael.friedrich at netways.de>
Date:   Wed Jun 26 16:00:42 2013 +0200

tests: icinga2 conversion: notification_options, custom attributes, etc

refs #2743

---

 tests/etc/2743.cfg |  122 +++++++++++++++++++++++++++++++++++++++++++++++++++-
 1 files changed, 120 insertions(+), 2 deletions(-)

diff --git a/tests/etc/2743.cfg b/tests/etc/2743.cfg
index ba9d7cb..05198bb 100644
--- a/tests/etc/2743.cfg
+++ b/tests/etc/2743.cfg
@@ -580,13 +580,29 @@ define servicedependency {
 ##############################################
 # serviceescalations
 ##############################################
+
+# hide servicegroup in template tree, and put escalation based on servicegroup
+define service {
+        name                            2743servicetemplate_sg01
+        servicegroups                   2743sg_many
+        check_command                   2743test2
+        use                             generic-service
+        register                        0
+}
+
+define service {
+        use                             2743servicetemplate_sg01
+        service_description             2743service_sg01
+        host_name                       2743dep_hostsvc03
+}
+
 # with host_name and service_description
 define serviceescalation {
         host_name                       2743dep_hostsvc05
         service_description             2743dep_svc01
         first_notification              2
         last_notification               6
-	    contact_groups			        2743cg_ops,2743cg_manager
+	    contact_groups			        2743cg_ops,2743cg_manager ; 2743testconfig-admin, 2743testconfig-operator, 2743testconfig-manager
 
 }
 
@@ -605,7 +621,7 @@ define serviceescalation {
         servicegroup_name               2743sg_many
         first_notification              2
         last_notification               1337
-        contact_groups                   2743cg_ops
+#        contact_groups                   2743cg_ops
         contacts                        2743testconfig-ticket
 }
 
@@ -618,6 +634,11 @@ define service {
         host_name                  	*
         check_command                   2743test2
         use                             generic-service
+        servicegroups                   2743sg_allservices
+}
+
+define servicegroup {
+        servicegroup_name              2743sg_allservices
 }
 
 ##############################################
@@ -688,5 +709,102 @@ define host {
 	hostgroups			+2347hg_additive03,2347hg_additive02
 }
 
+##############################################
+# notification_options 
+##############################################
+
+define contact{
+        contact_name                    2743testconfig-user-notification-options
+        use                             2743testconfig-generic-contact
+        alias                           Icinga Test User Notification Options
+        service_notification_options    c,f,s,u
+        email                           icinga at localhost
+}
+
+define host {
+        host_name                       2743host_notification_options
+        use                             2743hosttemplate01
+        notification_options    	    d,u,r
+}
+
+
+define service {
+        service_description             2743service_notification_options_all
+        host_name                       2743localhost1
+        use                             2743servicetemplatecontacts
+        notification_options    	    w,c,f,s,u,a,r,a
+}
+
+define service {
+        service_description             2743service_notification_options_none
+        host_name                       2743localhost1
+        use                             2743servicetemplatecontacts
+        notification_options    	    w,c,f,s,n,u,r,n
+}
+
+define service {
+        service_description             2743service_notification_options_some
+        host_name                       2743localhost1
+        use                             2743servicetemplatecontacts
+        notification_options    	    c,f,s,u
+}
+
+##############################################
+# null value (disable)
+##############################################
+
+define service {
+        service_description             2743service_nulled_contacts
+        host_name                       2743localhost1
+        use                             2743servicetemplatecontacts
+}
+
+
+##############################################
+# custom attr
+##############################################
+
+define host {
+        host_name                       2743host_custom_attr
+        use                             2743hosttemplate01
+        notes                           bumsti
+        icon_image                      ../../images/logos/Stats2.png
+        icon_image_alt                  bumsti alt icon text
+        action_url                      http://dev.icinga.org
+        notes_url                       http://docs.icinga.org
+        statusmap_image                 ../../images/logos/icinga.gif
+        2d_coords                       1,2
+        _CV                             cv bumsti01
+        _PASSWORD                       uraergergeheim
+        _DN                             cn=icinga2-dev-host,ou=icinga,ou=main,ou=IcingaConfig,ou=LConf,dc=icinga,dc=org
+}
+
 
+define service {
+        service_description             2743service_custom_attr
+        host_name                       2743localhost1
+        use                             2743servicetemplatecontacts
+        notes                           bumsti
+        icon_image                      ../../images/logos/Stats2.png
+        icon_image_alt                  bumsti alt icon text
+        action_url                      http://dev.icinga.org
+        notes_url                       http://docs.icinga.org
+        _CV                             cv bumsti02
+        _PASSWORD                       uraergergeheim
+        _DN                             cn=icinga2-dev-svc,ou=icinga,ou=main,ou=IcingaConfig,ou=LConf,dc=icinga,dc=org
+}
+
+define hostgroup {
+        hostgroup_name                  2743hg_custom_attr
+        notes                           bumsti
+        action_url                      http://dev.icinga.org
+        notes_url                       http://docs.icinga.org
+}
+
+define servicegroup {
+        servicegroup_name               2743sg_custom_attr
+        notes                           bumsti
+        action_url                      http://dev.icinga.org
+        notes_url                       http://docs.icinga.org
+}
 





More information about the icinga-checkins mailing list