aboutsummaryrefslogtreecommitdiff
path: root/manifests/base/vserver.pp
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/base/vserver.pp')
-rw-r--r--manifests/base/vserver.pp38
1 files changed, 38 insertions, 0 deletions
diff --git a/manifests/base/vserver.pp b/manifests/base/vserver.pp
new file mode 100644
index 0000000..433be5a
--- /dev/null
+++ b/manifests/base/vserver.pp
@@ -0,0 +1,38 @@
+class nodo::base::vserver {
+ class { 'timezone': }
+ class { 'syslog-ng::vserver': }
+
+ backupninja::sys { "sys":
+ ensure => present,
+ partitions => false,
+ hardware => false,
+ dosfdisk => false,
+ dohwinfo => false,
+ }
+
+ $hosting_type = hiera('nodo::vserver::hosting_type', 'direct')
+
+ case $hosting_type {
+ "direct": {
+ # Apply munin and monkeysphere configuration for
+ # for directly hosted nodes.
+ Munin_node <<| title == $::hostname |>>
+ Monkeysphere_host <<| title == $::hostname |>>
+ }
+ "third-party": {
+ # Apply munin and monkeysphere configuration for
+ # nodes hosted by third-parties.
+ munin_node { "${::hostname}": }
+ monkeysphere_host { "${::hostname}":
+ port => hiera('nodo::vserver::ssh_port', '22'),
+ }
+
+ # Nagios configuration
+ class { 'nodo::subsystem::monitor':
+ type => 'vserver',
+ use_nagios => hiera('nodo::vserver::use_nagios', false),
+ }
+ }
+ }
+
+}