summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabriel Filion <gabster@lelutin.ca>2015-04-19 15:52:56 -0400
committerGabriel Filion <gabster@lelutin.ca>2015-04-19 15:52:56 -0400
commit1746232173f04ce1536445280660b86ec490ae0d (patch)
treee0484647c962429af8948104044b4e519b8d12c4
parent0b20e1e0fd001cb0b688c6bf6971c8e7c3f743c6 (diff)
fix alignment and lint usage example
Example uses weird spacing in the beginning of the lines. Also the example usage of nagios::command is broken: it lacks the closing curly brace.
-rw-r--r--README66
1 files changed, 34 insertions, 32 deletions
diff --git a/README b/README
index 0949071..3ff5138 100644
--- a/README
+++ b/README
@@ -203,50 +203,52 @@ Examples
Usage example:
+~~~
node nagios {
- include nagios::apache
- include nagios::defaults
-
- # Declare another nagios command
- nagios::command { http_port: command_line
-=> '/usr/lib/nagios/plugins/check_http -p $ARG1$ -H $HOSTADDRESS$ -I
-$HOSTADDRESS$'
-
- # Declare unmanaged hosts
- nagios_host {
- 'router01.mydomain.com':
- alias => 'router01',
- notes => 'MyDomain Gateway',
- address => "10.0.0.1",
- use => 'generic-host';
- "router02.mydomain.com":
- alias => 'router02',
- address => '192.168.0.1',
- parents => 'router01',
- use => 'generic-host';
- }
+ include nagios::apache
+ include nagios::defaults
+
+ # Declare another nagios command
+ nagios::command { http_port:
+ command_line => '/usr/lib/nagios/plugins/check_http -p $ARG1$ -H $HOSTADDRESS$ -I $HOSTADDRESS$'
+ }
+
+ # Declare unmanaged hosts
+ nagios_host {
+ 'router01.mydomain.com':
+ alias => 'router01',
+ notes => 'MyDomain Gateway',
+ address => '10.0.0.1',
+ use => 'generic-host';
+ 'router02.mydomain.com':
+ alias => 'router02',
+ address => '192.168.0.1',
+ parents => 'router01',
+ use => 'generic-host';
+ }
}
node target {
- # Monitor this host
- class{'nagios::target':
- parents = 'router01'
- }
+ # Monitor this host
+ class{'nagios::target':
+ parents = 'router01'
+ }
- # monitor a service
- $apache2_port = 8080
- include apache2
+ # monitor a service
+ $apache2_port = 8080
+ include apache2
- # This actually does this somewhere:
- #nagios::service { "http_${apache2_port}":
- # check_command => "http_port!${apache2_port}"
- #}
+ # This actually does this somewhere:
+ #nagios::service { "http_${apache2_port}":
+ # check_command => "http_port!${apache2_port}"
+ #}
}
+~~~
TODO
====