Puppet: Change of icingaweb2 configuration deploy

- Only ensure presence no replacement if changed
- Config files pulled out of the working tree
- To restore, delete icingaweb configuration directory
This commit is contained in:
Marius Hein 2014-04-01 10:18:10 +02:00
parent 1beb837783
commit f98a39fd5a
8 changed files with 24 additions and 233 deletions

View File

@ -1,9 +0,0 @@
[internal_ldap_authentication]
backend = ldap
resource = internal_ldap
user_class = inetOrgPerson
user_name_attribute = uid
[internal_db_authentication]
backend = db
resource = internal_db

View File

@ -1,35 +0,0 @@
[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"

View File

@ -1,25 +0,0 @@
[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

View File

@ -1,19 +0,0 @@
[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

View File

@ -1,2 +0,0 @@
[icinga]
path = "/usr/local/icinga-mysql/var/rw/icinga.cmd"

View File

@ -1,100 +0,0 @@
[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

View File

@ -1,34 +0,0 @@
[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

View File

@ -637,27 +637,31 @@ file { '/etc/icingaweb':
}
file { '/etc/icingaweb/authentication.ini':
source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/authentication.ini',
replace => 'no',
source => 'puppet:////vagrant/config/authentication.ini',
owner => 'apache',
group => 'apache',
require => File['/etc/icingaweb']
}
file { '/etc/icingaweb/config.ini':
ensure => file,
replace => 'no',
source => 'puppet:////vagrant/config/config.ini',
owner => 'apache',
group => 'apache',
require => File['/etc/icingaweb']
}
file { '/etc/icingaweb/menu.ini':
source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/menu.ini',
replace => 'no',
source => 'puppet:////vagrant/config/menu.ini',
owner => 'apache',
group => 'apache',
# replace => false,
}
file { '/etc/icingaweb/resources.ini':
source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/resources.ini',
replace => 'no',
source => 'puppet:////vagrant/config/resources.ini',
owner => 'apache',
group => 'apache',
}
@ -668,20 +672,30 @@ 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':
source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/backends.ini',
replace => 'no',
source => 'puppet:////vagrant/config/modules/monitoring/backends.ini',
owner => 'apache',
group => 'apache',
}
file { '/etc/icingaweb/modules/monitoring/instances.ini':
source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/instances.ini',
replace => 'no',
source => 'puppet:////vagrant/config/modules/monitoring/instances.ini',
owner => 'apache',
group => 'apache',
}
file { '/etc/icingaweb/modules/monitoring/menu.ini':
source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/modules/monitoring/menu.ini',
replace => 'no',
source => 'puppet:////vagrant/config/modules/monitoring/menu.ini',
owner => 'apache',
group => 'apache',
}
@ -693,7 +707,8 @@ file { '/etc/icingaweb/dashboard':
}
file { '/etc/icingaweb/dashboard/dashboard.ini':
source => 'puppet:////vagrant/.vagrant-puppet/files/etc/icingaweb/dashboard/dashboard.ini',
replace => 'no',
source => 'puppet:////vagrant/config/dashboard/dashboard.ini',
owner => 'apache',
group => 'apache',
}