From eeb399a4d4b90062b3481e7a3b432a57b3698917 Mon Sep 17 00:00:00 2001 From: Marius Hein Date: Wed, 30 Apr 2014 13:04:41 +0200 Subject: [PATCH] Revert "Puppet: Change of icingaweb2 configuration deploy" This reverts commit f98a39fd5a9ebd72c9ec499e3eff3b5e536df121. --- .../files/etc/icingaweb/authentication.ini | 9 ++ .../etc/icingaweb/dashboard/dashboard.ini | 35 ++++++ .vagrant-puppet/files/etc/icingaweb/menu.ini | 25 +++++ .../icingaweb/modules/monitoring/backends.ini | 19 ++++ .../modules/monitoring/instances.ini | 2 + .../etc/icingaweb/modules/monitoring/menu.ini | 100 ++++++++++++++++++ .../files/etc/icingaweb/resources.ini | 34 ++++++ .vagrant-puppet/manifests/default.pp | 33 ++---- 8 files changed, 233 insertions(+), 24 deletions(-) create mode 100644 .vagrant-puppet/files/etc/icingaweb/authentication.ini create mode 100644 .vagrant-puppet/files/etc/icingaweb/dashboard/dashboard.ini create mode 100644 .vagrant-puppet/files/etc/icingaweb/menu.ini create mode 100644 .vagrant-puppet/files/etc/icingaweb/modules/monitoring/backends.ini create mode 100644 .vagrant-puppet/files/etc/icingaweb/modules/monitoring/instances.ini create mode 100644 .vagrant-puppet/files/etc/icingaweb/modules/monitoring/menu.ini create mode 100644 .vagrant-puppet/files/etc/icingaweb/resources.ini diff --git a/.vagrant-puppet/files/etc/icingaweb/authentication.ini b/.vagrant-puppet/files/etc/icingaweb/authentication.ini new file mode 100644 index 000000000..551cee143 --- /dev/null +++ b/.vagrant-puppet/files/etc/icingaweb/authentication.ini @@ -0,0 +1,9 @@ +[internal_ldap_authentication] +backend = ldap +resource = internal_ldap +user_class = inetOrgPerson +user_name_attribute = uid + +[internal_db_authentication] +backend = db +resource = internal_db diff --git a/.vagrant-puppet/files/etc/icingaweb/dashboard/dashboard.ini b/.vagrant-puppet/files/etc/icingaweb/dashboard/dashboard.ini new file mode 100644 index 000000000..50e5a6373 --- /dev/null +++ b/.vagrant-puppet/files/etc/icingaweb/dashboard/dashboard.ini @@ -0,0 +1,35 @@ +[Incidents] +title = "Current incidents" + +[Incidents.Service Problems] +url = "monitoring/list/services" +service_problem = 1 +limit = 10 +sort = service_severity + +[Incidents.Recently Recovered Services] +url = "monitoring/list/services" +sort = "service_last_state_change" +service_state = 0 +limit = 10 +dir = "desc" + +[Incidents.Host Problems] +url = "monitoring/list/hosts" +host_problem = 1 +sort = host_severity + +[Landing] +title = "Landing page" + +[Landing.Hostgroups] +url = "monitoring/chart/hostgroup?height=400&width=500" + +[Landing.Servicegroups] +url = "monitoring/chart/servicegroup?height=360&width=450" + +[Landing.Unhandled Problem Services] +url = "monitoring/list/services?service_handled=0&service_problem=1" + +[Landing.Unhandled Problem Hosts] +url = "monitoring/list/hosts?host_handled=0&host_problem=1" diff --git a/.vagrant-puppet/files/etc/icingaweb/menu.ini b/.vagrant-puppet/files/etc/icingaweb/menu.ini new file mode 100644 index 000000000..b63914202 --- /dev/null +++ b/.vagrant-puppet/files/etc/icingaweb/menu.ini @@ -0,0 +1,25 @@ +[Dashboard] +title = "Dashboard" +url = "dashboard" +icon = "img/icons/dashboard.png" +priority = 10 + +[System] +icon = img/icons/configuration.png +priority = 200 + +[System.Preferences] +title = "Preferences" +url = "preference" +priority = 200 + +[System.Configuration] +title = "Configuration" +url = "config" +priority = 300 + +[Logout] +url = "authentication/logout" +icon = img/icons/logout.png +priority = 300 + diff --git a/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/backends.ini b/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/backends.ini new file mode 100644 index 000000000..6805f2e8b --- /dev/null +++ b/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/backends.ini @@ -0,0 +1,19 @@ +[localdb] + +type = ido +resource = "ido" + +[locallive] +disabled = "1" +type = livestatus +resource = livestatus + +[localfile] +disabled = "1" +type = statusdat +resource = statusdat + +;[localfailsafe] +;enabled=false +;type = combo +;backends = localdb, locallive, localfile diff --git a/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/instances.ini b/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/instances.ini new file mode 100644 index 000000000..2f54e11e3 --- /dev/null +++ b/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/instances.ini @@ -0,0 +1,2 @@ +[icinga] +path = "/usr/local/icinga-mysql/var/rw/icinga.cmd" diff --git a/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/menu.ini b/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/menu.ini new file mode 100644 index 000000000..0c7e37dea --- /dev/null +++ b/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/menu.ini @@ -0,0 +1,100 @@ + +[Problems] +priority = 20 +icon = "img/icons/error.png" + +[Problems.Unhandled Hosts] +priority = 40 +url = "monitoring/list/hosts?host_problem=1&host_handled=0" + +[Problems.Unhandled Services] +priority = 40 +url = "monitoring/list/services?service_problem=1&service_handled=0&sort=service_severity" + +[Problems.Host Problems] +priority = 50 +url = "monitoring/list/hosts?host_problem=1&sort=host_severity" + +[Problems.Service Problems] +priority = 50 +url = "monitoring/list/services?service_problem=1&sort=service_severity&dir=desc" + +[Problems.Current Downtimes] +url = "monitoring/list/downtimes?downtime_is_in_effect=1" + +[Overview] +priority = 30 +icon = "img/icons/hostgroup.png" + +[Overview.Tactical Overview] +title = "Tactical Overview" +url = "monitoring/tactical" +priority = 40 + +[Overview.Hosts] +title = "Hosts" +url = "monitoring/list/hosts" +priority = 50 + +[Overview.Services] +title = "Services" +url = "monitoring/list/services" +priority = 50 + +[Overview.Servicematrix] +title = "Servicematrix" +url = "monitoring/list/servicematrix" +priority = 51 + +[Overview.Servicegroups] +title = "Servicegroups" +url = "monitoring/list/servicegroups" +priority = 60 + +[Overview.Hostgroups] +title = "Hostgroups" +url = "monitoring/list/hostgroups" +priority = 60 + +[Overview.Contactgroups] +title = "Contactgroups" +url = "monitoring/list/contactgroups" +priority = 61 + +[Overview.Downtimes] +title = "Downtimes" +url = "monitoring/list/downtimes" +priority = 70 + +[Overview.Comments] +title = "Comments" +url = "monitoring/list/comments" +priority = 70 + +[History] +icon = "img/icons/history.png" + +[History.Critical Events] +title = "Critical Events" +url = "monitoring/list/statehistorysummary" +priority = 50 + +[History.Notifications] +title = "Notifications" +url = "monitoring/list/notifications" + +[History.Events] +title = "All Events" +url = "monitoring/list/eventhistory?raw_timestamp>=-2+days" + +[System.Process Info] +title = "Process Info" +url = "monitoring/process/info" +priority = 120 + +[System.Performance Info] +title = "Performance Info" +url = "monitoring/process/performance" +priority = 130 + + diff --git a/.vagrant-puppet/files/etc/icingaweb/resources.ini b/.vagrant-puppet/files/etc/icingaweb/resources.ini new file mode 100644 index 000000000..2ef51e921 --- /dev/null +++ b/.vagrant-puppet/files/etc/icingaweb/resources.ini @@ -0,0 +1,34 @@ +[internal_db] +type = db +db = mysql +host = localhost +port = 3306 +password = icingaweb +username = icingaweb +dbname = icingaweb + +[ido] +type = db +db = mysql +host = localhost +port = 3306 +password = icinga +username = icinga +dbname = icinga + +[statusdat] +type = statusdat +status_file = /usr/local/icinga-mysql/var/status.dat +object_file = /usr/local/icinga-mysql/var/objects.cache + +[livestatus] +type = livestatus +socket = /usr/local/icinga-mysql/var/rw/live + +[internal_ldap] +type = ldap +hostname = localhost +port = 389 +root_dn = "ou=people, dc=icinga, dc=org" +bind_dn = "cn=admin,cn=config" +bind_pw = admin diff --git a/.vagrant-puppet/manifests/default.pp b/.vagrant-puppet/manifests/default.pp index 7723f563e..7726a27ed 100644 --- a/.vagrant-puppet/manifests/default.pp +++ b/.vagrant-puppet/manifests/default.pp @@ -637,31 +637,27 @@ file { '/etc/icingaweb': } file { '/etc/icingaweb/authentication.ini': - replace => 'no', - source => 'puppet:////vagrant/config/authentication.ini', + source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/authentication.ini', owner => 'apache', group => 'apache', require => File['/etc/icingaweb'] } file { '/etc/icingaweb/config.ini': - replace => 'no', - source => 'puppet:////vagrant/config/config.ini', + ensure => file, owner => 'apache', group => 'apache', - require => File['/etc/icingaweb'] } file { '/etc/icingaweb/menu.ini': - replace => 'no', - source => 'puppet:////vagrant/config/menu.ini', + source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/menu.ini', owner => 'apache', group => 'apache', + # replace => false, } file { '/etc/icingaweb/resources.ini': - replace => 'no', - source => 'puppet:////vagrant/config/resources.ini', + source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/resources.ini', owner => 'apache', group => 'apache', } @@ -672,30 +668,20 @@ file { ['/etc/icingaweb/enabledModules', '/etc/icingaweb/modules', '/etc/icingaw group => 'apache', } -file { '/etc/icingaweb/enabledModules/monitoring': - ensure => 'link', - target => '/vagrant/modules/monitoring', - owner => 'apache', - group => 'apache', -} - file { '/etc/icingaweb/modules/monitoring/backends.ini': - replace => 'no', - source => 'puppet:////vagrant/config/modules/monitoring/backends.ini', + source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/backends.ini', owner => 'apache', group => 'apache', } file { '/etc/icingaweb/modules/monitoring/instances.ini': - replace => 'no', - source => 'puppet:////vagrant/config/modules/monitoring/instances.ini', + source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/instances.ini', owner => 'apache', group => 'apache', } file { '/etc/icingaweb/modules/monitoring/menu.ini': - replace => 'no', - source => 'puppet:////vagrant/config/modules/monitoring/menu.ini', + source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/menu.ini', owner => 'apache', group => 'apache', } @@ -707,8 +693,7 @@ file { '/etc/icingaweb/dashboard': } file { '/etc/icingaweb/dashboard/dashboard.ini': - replace => 'no', - source => 'puppet:////vagrant/config/dashboard/dashboard.ini', + source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/dashboard/dashboard.ini', owner => 'apache', group => 'apache', }