From 4591a91f7a8b169d0aa3ccb46357c60f8dcb7079 Mon Sep 17 00:00:00 2001 From: Jerome Charaoui Date: Thu, 13 May 2010 14:12:07 -0400 Subject: remove tabs and trailing whitespaces in manifests --- manifests/client.pp | 12 +++++----- manifests/client/base.pp | 12 +++++----- manifests/client/centos.pp | 2 +- manifests/client/darwin.pp | 38 +++++++++++++++--------------- manifests/client/debian.pp | 18 +++++++------- manifests/client/gentoo.pp | 4 ++-- manifests/client/openbsd.pp | 2 +- manifests/client/package.pp | 8 +++---- manifests/host.pp | 16 ++++++------- manifests/init.pp | 10 ++++---- manifests/plugin.pp | 52 ++++++++++++++++++++--------------------- manifests/plugin/scriptpaths.pp | 10 ++++---- manifests/plugins/interfaces.pp | 6 ++--- manifests/plugins/linux.pp | 8 +++---- manifests/plugins/vserver.pp | 4 ++-- manifests/register.pp | 16 ++++++------- manifests/register_snmp.pp | 10 ++++---- manifests/remoteplugin.pp | 26 ++++++++++----------- manifests/snmp_collector.pp | 22 ++++++++--------- 19 files changed, 138 insertions(+), 138 deletions(-) diff --git a/manifests/client.pp b/manifests/client.pp index 24d84da..273070d 100644 --- a/manifests/client.pp +++ b/manifests/client.pp @@ -5,12 +5,12 @@ class munin::client inherits munin { - $munin_port_real = $munin_port ? { '' => 4949, default => $munin_port } - $munin_host_real = $munin_host ? { - '' => '*', - 'fqdn' => '*', - default => $munin_host - } + $munin_port_real = $munin_port ? { '' => 4949, default => $munin_port } + $munin_host_real = $munin_host ? { + '' => '*', + 'fqdn' => '*', + default => $munin_host + } case $operatingsystem { openbsd: { include munin::client::openbsd } diff --git a/manifests/client/base.pp b/manifests/client/base.pp index b3fcc4a..afa12a0 100644 --- a/manifests/client/base.pp +++ b/manifests/client/base.pp @@ -1,6 +1,6 @@ class munin::client::base { service { 'munin-node': - ensure => running, + ensure => running, enable => true, hasstatus => true, hasrestart => true, @@ -14,10 +14,10 @@ class munin::client::base { default => $munin_allow } file {'/etc/munin/munin-node.conf': - content => template("munin/munin-node.conf.$operatingsystem"), + content => template("munin/munin-node.conf.$operatingsystem"), notify => Service['munin-node'], - mode => 0644, owner => root, group => 0, - } - munin::register { $fqdn: } - include munin::plugins::base + mode => 0644, owner => root, group => 0, + } + munin::register { $fqdn: } + include munin::plugins::base } diff --git a/manifests/client/centos.pp b/manifests/client/centos.pp index 46a7e3f..42e8c59 100644 --- a/manifests/client/centos.pp +++ b/manifests/client/centos.pp @@ -1,3 +1,3 @@ class munin::client::centos inherits munin::client::package { - include munin::plugins::centos + include munin::plugins::centos } diff --git a/manifests/client/darwin.pp b/manifests/client/darwin.pp index f6fc95f..369a605 100644 --- a/manifests/client/darwin.pp +++ b/manifests/client/darwin.pp @@ -1,21 +1,21 @@ class munin::client::darwin { - file { "/usr/share/snmp/snmpd.conf": - mode => 744, - content => template("munin/darwin_snmpd.conf.erb"), - group => 0, - owner => root, - } - delete_matching_line{"startsnmpdno": - file => "/etc/hostconfig", - pattern => "SNMPSERVER=-NO-", - } - line { "startsnmpdyes": - file => "/etc/hostconfig", - line => "SNMPSERVER=-YES-", - notify => Exec["/sbin/SystemStarter start SNMP"], - } - exec{"/sbin/SystemStarter start SNMP": - noop => false, - } - munin::register_snmp { $fqdn: } + file { "/usr/share/snmp/snmpd.conf": + mode => 744, + content => template("munin/darwin_snmpd.conf.erb"), + group => 0, + owner => root, + } + delete_matching_line{"startsnmpdno": + file => "/etc/hostconfig", + pattern => "SNMPSERVER=-NO-", + } + line { "startsnmpdyes": + file => "/etc/hostconfig", + line => "SNMPSERVER=-YES-", + notify => Exec["/sbin/SystemStarter start SNMP"], + } + exec{"/sbin/SystemStarter start SNMP": + noop => false, + } + munin::register_snmp { $fqdn: } } diff --git a/manifests/client/debian.pp b/manifests/client/debian.pp index a6d677e..97f5fbf 100644 --- a/manifests/client/debian.pp +++ b/manifests/client/debian.pp @@ -1,15 +1,15 @@ class munin::client::debian inherits munin::client::package { # the plugin will need that - package { "iproute": ensure => installed } + package { "iproute": ensure => installed } - Service["munin-node"]{ - # sarge's munin-node init script has no status - hasstatus => $lsbdistcodename ? { sarge => false, default => true } - } + Service["munin-node"]{ + # sarge's munin-node init script has no status + hasstatus => $lsbdistcodename ? { sarge => false, default => true } + } File["/etc/munin/munin-node.conf"]{ - content => template("munin/munin-node.conf.$operatingsystem.$lsbdistcodename"), + content => template("munin/munin-node.conf.$operatingsystem.$lsbdistcodename"), } - # workaround bug in munin_node_configure - plugin { "postfix_mailvolume": ensure => absent } - include munin::plugins::debian + # workaround bug in munin_node_configure + plugin { "postfix_mailvolume": ensure => absent } + include munin::plugins::debian } diff --git a/manifests/client/gentoo.pp b/manifests/client/gentoo.pp index 53d472b..c24d317 100644 --- a/manifests/client/gentoo.pp +++ b/manifests/client/gentoo.pp @@ -3,6 +3,6 @@ class munin::client::gentoo inherits munin::client::package { name => 'munin', category => 'net-analyzer', } - - include munin::plugins::gentoo + + include munin::plugins::gentoo } diff --git a/manifests/client/openbsd.pp b/manifests/client/openbsd.pp index 90bf7df..c10a474 100644 --- a/manifests/client/openbsd.pp +++ b/manifests/client/openbsd.pp @@ -5,7 +5,7 @@ class munin::client::openbsd inherits munin::client::base { source => "puppet://$server/modules/munin/openbsd/package/munin_openbsd.tar.gz", owner => root, group => 0, mode => 0600; } - package{ [ 'p5-Compress-Zlib', 'p5-Crypt-SSLeay', 'p5-HTML-Parser', + package{ [ 'p5-Compress-Zlib', 'p5-Crypt-SSLeay', 'p5-HTML-Parser', 'p5-HTML-Tagset', 'p5-HTTP-GHTTP', 'p5-LWP-UserAgent-Determined', 'p5-Net-SSLeay', 'p5-Net-Server', 'p5-URI', 'p5-libwww', 'pcre', 'curl' ]: ensure => installed, diff --git a/manifests/client/package.pp b/manifests/client/package.pp index 84fcf5c..18566b8 100644 --- a/manifests/client/package.pp +++ b/manifests/client/package.pp @@ -1,11 +1,11 @@ class munin::client::package inherits munin::client::base { - package { 'munin-node': ensure => installed } + package { 'munin-node': ensure => installed } Service['munin-node']{ require => Package[munin-node], } File['/etc/munin/munin-node.conf']{ - # this has to be installed before the package, so the postinst can - # boot the munin-node without failure! - before => Package['munin-node'], + # this has to be installed before the package, so the postinst can + # boot the munin-node without failure! + before => Package['munin-node'], } } diff --git a/manifests/host.pp b/manifests/host.pp index 9fd637d..87d3255 100644 --- a/manifests/host.pp +++ b/manifests/host.pp @@ -4,9 +4,9 @@ class munin::host inherits munin { - package {"munin": ensure => installed, } + package {"munin": ensure => installed, } - File <<| tag == 'munin' |>> + File <<| tag == 'munin' |>> file{'/etc/munin/munin.conf.header': source => [ "puppet://$server/modules/site-munin/config/host/${fqdn}/munin.conf.header", @@ -18,12 +18,12 @@ class munin::host inherits munin owner => root, group => 0, mode => 0644; } - concatenated_file { "/etc/munin/munin.conf": - dir => '/var/lib/puppet/modules/munin/nodes', - header => "/etc/munin/munin.conf.header", - } - - file { ["/var/log/munin-update.log", "/var/log/munin-limits.log", + concatenated_file { "/etc/munin/munin.conf": + dir => '/var/lib/puppet/modules/munin/nodes', + header => "/etc/munin/munin.conf.header", + } + + file { ["/var/log/munin-update.log", "/var/log/munin-limits.log", "/var/log/munin-graph.log", "/var/log/munin-html.log"]: ensure => present, mode => 640, owner => munin, group => 0; diff --git a/manifests/init.pp b/manifests/init.pp index 5c4feeb..bae83a4 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -2,17 +2,17 @@ # munin module # munin.pp - everything a sitewide munin installation needs # Copyright (C) 2007 David Schmitt -# +# # Copyright 2008, Puzzle ITC GmbH # Marcel Härry haerry+puppet(at)puzzle.ch # Simon Josi josi+puppet(at)puzzle.ch # -# This program is free software; you can redistribute -# it and/or modify it under the terms of the GNU -# General Public License version 3 as published by +# This program is free software; you can redistribute +# it and/or modify it under the terms of the GNU +# General Public License version 3 as published by # the Free Software Foundation. # -# the port is a parameter so vservers can share +# the port is a parameter so vservers can share # IP addresses and still be happy class munin { diff --git a/manifests/plugin.pp b/manifests/plugin.pp index 1fa4651..cdaa17d 100644 --- a/manifests/plugin.pp +++ b/manifests/plugin.pp @@ -17,10 +17,10 @@ define munin::plugin ( $plugin = "/etc/munin/plugins/$name" $plugin_conf = "/etc/munin/plugin-conf.d/$name.conf" case $ensure { - "absent": { - file { $plugin: ensure => absent, } - } - default: { + "absent": { + file { $plugin: ensure => absent, } + } + default: { case $kernel { openbsd: { $basic_require = File['/var/run/munin'] } default: { $basic_require = Package['munin-node'] } @@ -30,35 +30,35 @@ define munin::plugin ( } else { $real_require = $basic_require } - file { $plugin: - ensure => "${real_script_path}/${plugin_src}", - require => $real_require, - notify => Service['munin-node']; - } + file { $plugin: + ensure => "${real_script_path}/${plugin_src}", + require => $real_require, + notify => Service['munin-node']; + } - } + } } case $config { - '': { - file { $plugin_conf: ensure => absent } - } - default: { - case $ensure { - absent: { - file { $plugin_conf: ensure => absent } - } - default: { - file { $plugin_conf: - content => "[${name}]\n$config\n", - mode => 0644, owner => root, group => 0, - } + '': { + file { $plugin_conf: ensure => absent } + } + default: { + case $ensure { + absent: { + file { $plugin_conf: ensure => absent } + } + default: { + file { $plugin_conf: + content => "[${name}]\n$config\n", + mode => 0644, owner => root, group => 0, + } if $require { File[$plugin_conf]{ require +> $require, } } - } - } - } + } + } + } } } diff --git a/manifests/plugin/scriptpaths.pp b/manifests/plugin/scriptpaths.pp index ebaa6fa..ce27384 100644 --- a/manifests/plugin/scriptpaths.pp +++ b/manifests/plugin/scriptpaths.pp @@ -1,9 +1,9 @@ class munin::plugin::scriptpaths { case $operatingsystem { - gentoo: { $script_path = "/usr/libexec/munin/plugins" } - debian: { $script_path = "/usr/share/munin/plugins" } - centos: { $script_path = "/usr/share/munin/plugins" } - openbsd: { $script_path = "/opt/munin/lib/plugins/" } - default: { $script_path = "/usr/share/munin/plugins" } + gentoo: { $script_path = "/usr/libexec/munin/plugins" } + debian: { $script_path = "/usr/share/munin/plugins" } + centos: { $script_path = "/usr/share/munin/plugins" } + openbsd: { $script_path = "/opt/munin/lib/plugins/" } + default: { $script_path = "/usr/share/munin/plugins" } } } diff --git a/manifests/plugins/interfaces.pp b/manifests/plugins/interfaces.pp index 99b85ba..df0828c 100644 --- a/manifests/plugins/interfaces.pp +++ b/manifests/plugins/interfaces.pp @@ -8,14 +8,14 @@ class munin::plugins::interfaces inherits munin::plugins::base { case $operatingsystem { openbsd: { $if_errs = gsub(split($interfaces, " |,"), "(.+)", "if_errcoll_\\1") - munin::plugin{ + munin::plugin{ $if_errs: ensure => "if_errcoll_"; } } default: { $if_errs = gsub(split($interfaces, " |,"), "(.+)", "if_err_\\1") - munin::plugin{ - $if_errs: ensure => "if_err_"; + munin::plugin{ + $if_errs: ensure => "if_err_"; } } } diff --git a/manifests/plugins/linux.pp b/manifests/plugins/linux.pp index c7beb59..86696cc 100644 --- a/manifests/plugins/linux.pp +++ b/manifests/plugins/linux.pp @@ -1,9 +1,9 @@ class munin::plugins::linux inherits munin::plugins::base { munin::plugin { - [ df_abs, forks, df_inode, irqstats, entropy, open_inodes ]: - ensure => present; - acpi: - ensure => $acpi_available; + [ df_abs, forks, df_inode, irqstats, entropy, open_inodes ]: + ensure => present; + acpi: + ensure => $acpi_available; } include munin::plugins::interfaces diff --git a/manifests/plugins/vserver.pp b/manifests/plugins/vserver.pp index bce28a1..f24af07 100644 --- a/manifests/plugins/vserver.pp +++ b/manifests/plugins/vserver.pp @@ -1,7 +1,7 @@ class munin::plugins::vserver inherits munin::plugins::base { munin::plugin { - [ netstat, processes ]: - ensure => present; + [ netstat, processes ]: + ensure => present; } } diff --git a/manifests/register.pp b/manifests/register.pp index 59500a0..05d8f2a 100644 --- a/manifests/register.pp +++ b/manifests/register.pp @@ -3,7 +3,7 @@ define munin::register( $port = 'absent' ) { - $munin_port_real = $port ? { + $munin_port_real = $port ? { 'absent' => $munin_port ? { '' => 4949, default => $munin_port @@ -11,20 +11,20 @@ define munin::register( default => $port } - $munin_host_real = $host ? { + $munin_host_real = $host ? { 'absent' => $munin_host ? { '' => $fqdn, 'fqdn' => $fqdn, default => $munin_host }, default => $host - } + } - @@file { "/var/lib/puppet/modules/munin/nodes/${name}_${munin_port_real}": - ensure => present, - content => template("munin/defaultclient.erb"), - tag => 'munin', - } + @@file { "/var/lib/puppet/modules/munin/nodes/${name}_${munin_port_real}": + ensure => present, + content => template("munin/defaultclient.erb"), + tag => 'munin', + } } diff --git a/manifests/register_snmp.pp b/manifests/register_snmp.pp index e74ba44..ebd494a 100644 --- a/manifests/register_snmp.pp +++ b/manifests/register_snmp.pp @@ -3,11 +3,11 @@ define munin::register_snmp( $snmpd_testplugin = 'load' ) { - $munin_port_real = $munin_port ? { '' => 4949, default => $munin_port } - $munin_host_real = $munin_host ? { - '' => '*', - 'fqdn' => '*', - default => $munin_host + $munin_port_real = $munin_port ? { '' => 4949, default => $munin_port } + $munin_host_real = $munin_host ? { + '' => '*', + 'fqdn' => '*', + default => $munin_host } exec{"register_snmp_munin_for_${name}": command => "munin-node-configure-snmp ${name} | sh", diff --git a/manifests/remoteplugin.pp b/manifests/remoteplugin.pp index 4bca235..ce87492 100644 --- a/manifests/remoteplugin.pp +++ b/manifests/remoteplugin.pp @@ -1,18 +1,18 @@ define munin::remoteplugin($ensure = "present", $source, $config = '') { case $ensure { - "absent": { munin::plugin{ $name: ensure => absent } } - default: { - file { - "/var/lib/puppet/modules/munin/plugins/${name}": - source => $source, - mode => 0755, owner => root, group => 0; - } - munin::plugin { $name: - ensure => $ensure, - config => $config, - script_path_in => "/var/lib/puppet/modules/munin/plugins", - } - } + "absent": { munin::plugin{ $name: ensure => absent } } + default: { + file { + "/var/lib/puppet/modules/munin/plugins/${name}": + source => $source, + mode => 0755, owner => root, group => 0; + } + munin::plugin { $name: + ensure => $ensure, + config => $config, + script_path_in => "/var/lib/puppet/modules/munin/plugins", + } + } } } diff --git a/manifests/snmp_collector.pp b/manifests/snmp_collector.pp index 4f72b95..6f3fe34 100644 --- a/manifests/snmp_collector.pp +++ b/manifests/snmp_collector.pp @@ -1,14 +1,14 @@ class munin::snmp_collector{ - file { - "/var/lib/puppet/modules/munin/create_snmp_links": - source => "puppet://$server/modules/munin/create_snmp_links.sh", - mode => 755, owner => root, group => 0; - } + file { + "/var/lib/puppet/modules/munin/create_snmp_links": + source => "puppet://$server/modules/munin/create_snmp_links.sh", + mode => 755, owner => root, group => 0; + } - exec { "create_snmp_links": - command => "/var/lib/puppet/modules/munin/create_snmp_links /var/lib/puppet/modules/munin/nodes", - require => File["snmp_links"], - timeout => "2048", - schedule => daily - } + exec { "create_snmp_links": + command => "/var/lib/puppet/modules/munin/create_snmp_links /var/lib/puppet/modules/munin/nodes", + require => File["snmp_links"], + timeout => "2048", + schedule => daily + } } -- cgit v1.2.3