[icinga-checkins] icinga.org: icinga-vagrant/master: icinga2x: Add icingaweb2-module-graphite

git at icinga.org git at icinga.org
Wed Feb 17 00:58:06 CET 2016


Module: icinga-vagrant
Branch: master
Commit: 57770c07c84ed1d29817e044bbb905b7a3037414
URL:    https://git.icinga.org/?p=icinga-vagrant.git;a=commit;h=57770c07c84ed1d29817e044bbb905b7a3037414

Author: Michael Friedrich <michael.friedrich at netways.de>
Date:   Wed Feb 17 00:36:23 2016 +0100

icinga2x: Add icingaweb2-module-graphite

---

 .../etc/icingaweb2/modules/graphite/config.ini     |    2 ++
 icinga2x/manifests/default.pp                      |   30 +++++++++++++++++++-
 2 files changed, 31 insertions(+), 1 deletion(-)

diff --git a/icinga2x/files/etc/icingaweb2/modules/graphite/config.ini b/icinga2x/files/etc/icingaweb2/modules/graphite/config.ini
new file mode 100644
index 0000000..b46320e
--- /dev/null
+++ b/icinga2x/files/etc/icingaweb2/modules/graphite/config.ini
@@ -0,0 +1,2 @@
+[graphite]
+web_url = http://192.168.33.5:8003
diff --git a/icinga2x/manifests/default.pp b/icinga2x/manifests/default.pp
index 1aff945..45cb694 100644
--- a/icinga2x/manifests/default.pp
+++ b/icinga2x/manifests/default.pp
@@ -332,7 +332,7 @@ file { 'nagvis-core-functions-index.php':
 }
 
 ####################################
-# Graphite
+# Dashing
 ####################################
 
 package { [ 'rubygems', 'rubygem-bundler', 'ruby-devel', 'openssl', 'gcc-c++', 'make', 'nodejs' ]:
@@ -455,6 +455,34 @@ class { 'graphite':
 #  require	=> Class['graphite'],
 #}
 
+# icingaweb2 module
+icingaweb2::module { 'graphite':
+  builtin => false
+}
+
+# ship box specific graphite module config
+file {'/etc/icingaweb2/modules/graphite':
+  ensure => directory,
+  owner  => root,
+  group  => icingaweb2,
+  mode => '2770',
+  require => [ Package['icingaweb2'], File['/etc/icingaweb2/modules'] ]
+} ->
+file { '/etc/icingaweb2/modules/graphite/templates':
+  ensure => link,
+  force => true,
+  target => '/usr/share/icingaweb2/modules/graphite/sample-config/icinga2/templates'
+} ->
+file { '/etc/icingaweb2/modules/graphite/config.ini':
+  ensure => file,
+  owner => root,
+  group => icingaweb2,
+  mode => '2770',
+  source => 'puppet:////vagrant/files/etc/icingaweb2/modules/graphite/config.ini', #TODO use hiera and templates
+  require => File['/etc/icingaweb2/modules/graphite']
+}
+
+
 ####################################
 # Grafana
 ####################################



More information about the icinga-checkins mailing list