From 7bd9e7d7a34b9804f0cd1f22ecdd2d3212935bfb Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Fri, 26 Aug 2011 15:08:32 -0300 Subject: Adding $munin_port and $monkeysphere_ssh_port --- manifests/physical.pp | 7 ++++++- manifests/vserver.pp | 13 ++++++++++--- 2 files changed, 16 insertions(+), 4 deletions(-) (limited to 'manifests') diff --git a/manifests/physical.pp b/manifests/physical.pp index 95f863d..657c7d2 100644 --- a/manifests/physical.pp +++ b/manifests/physical.pp @@ -49,7 +49,12 @@ class nodo::physical inherits nodo { } # Monkeysphere configuration - monkeysphere_host { "$hostname": } + monkeysphere_host { "$hostname": + port => $monkeysphere_ssh_port ? { + false => '', + default => $monkeysphere_ssh_port, + } + } # SMART monitoring include munin::plugins::smart diff --git a/manifests/vserver.pp b/manifests/vserver.pp index 2d2ab55..55ed957 100644 --- a/manifests/vserver.pp +++ b/manifests/vserver.pp @@ -37,7 +37,8 @@ class nodo::vserver inherits nodo { define instance($context, $ensure = 'running', $proxy = false, $puppetmaster = false, $gitd = false, $mail = false, $icecast = false, $sound = false, $ticket = false, - $memory_limit = false, $distro = 'squeeze', $dns = false) { + $memory_limit = false, $distro = 'squeeze', $dns = false, + $munin_port = false, $monkeysphere_ssh_port = false) { # set instance id if $context <= 9 { @@ -81,12 +82,18 @@ class nodo::vserver inherits nodo { # Create a munin virtual resource to be realized in the node @@munin_node { "$name": - port => "49$id", + port => $munin_port ? { + false => "49$id", + default => $munin_port, + } } # Create a monkeysphere virtual resource to be realized in the node @@monkeysphere_host { "$name": - port => "22$id", + port => $monkeysphere_ssh_port ? { + false => "22$id", + default => $monkeysphere_ssh_port, + } } # Sound support -- cgit v1.2.3