diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2013-01-24 15:40:46 -0200 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2013-01-24 15:40:46 -0200 |
commit | 51622c10f922671cb8bcb1cda874f64ea932a462 (patch) | |
tree | 3e1540a8eca3b4c463edbdeb9e99baa695786933 | |
parent | 8abf2781a7c968d22a5ca5551f7989bbd15a3204 (diff) | |
download | puppet-nodo-51622c10f922671cb8bcb1cda874f64ea932a462.tar.gz puppet-nodo-51622c10f922671cb8bcb1cda874f64ea932a462.tar.bz2 |
Monkeysphere host really needs to be a resource and not a class
-rw-r--r-- | manifests/host.pp | 4 | ||||
-rw-r--r-- | manifests/plug.pp | 2 | ||||
-rw-r--r-- | manifests/subsystems/monkeysphere.pp | 2 | ||||
-rw-r--r-- | manifests/vserver.pp | 8 | ||||
-rw-r--r-- | manifests/vserver/instance.pp | 2 |
5 files changed, 9 insertions, 9 deletions
diff --git a/manifests/host.pp b/manifests/host.pp index ee6c18e..42e739d 100644 --- a/manifests/host.pp +++ b/manifests/host.pp @@ -6,10 +6,10 @@ class nodo::host inherits nodo { include sysctl include utils::physical include resolver - - class { 'monkeysphere_host': } class { 'syslog-ng': } + monkeysphere_host { "${::hostname}": } + # Firewall configuration class { 'firewall': } diff --git a/manifests/plug.pp b/manifests/plug.pp index 630be3a..f5992fc 100644 --- a/manifests/plug.pp +++ b/manifests/plug.pp @@ -5,7 +5,7 @@ class nodo::plug inherits nodo { include sysctl include resolver - class { 'monkeysphere_host': } + monkeysphere_host { "${::hostname}": } class { 'firewall': } diff --git a/manifests/subsystems/monkeysphere.pp b/manifests/subsystems/monkeysphere.pp index 54bf078..76530ca 100644 --- a/manifests/subsystems/monkeysphere.pp +++ b/manifests/subsystems/monkeysphere.pp @@ -1,4 +1,4 @@ -class monkeysphere_host( +define monkeysphere_host( $port = hiera('nodo::monkeysphere_host::ssh_port', ''), $mail_recipient = hiera('nodo::root_mail_recipient', 'nobody') ) { diff --git a/manifests/vserver.pp b/manifests/vserver.pp index 9feb030..b68d501 100644 --- a/manifests/vserver.pp +++ b/manifests/vserver.pp @@ -20,8 +20,8 @@ class nodo::vserver inherits nodo { "direct": { # Apply munin and monkeysphere configuration for # for directly hosted nodes. - Munin_node <<| title == $hostname |>> - Monkeysphere_host <<| title == $hostname |>> + Munin_node <<| title == $::hostname |>> + Monkeysphere_host <<| title == $::hostname |>> # Set proxy configuration $nodo_https_proxy = 'yes' @@ -29,8 +29,8 @@ class nodo::vserver inherits nodo { "third-party": { # Apply munin and monkeysphere configuration for # nodes hosted by third-parties. - munin_node { "$hostname": } - monkeysphere_host { "$hostname": + munin_node { "${::hostname}": } + monkeysphere_host { "${::hostname}": port => $node_ssh_port, } diff --git a/manifests/vserver/instance.pp b/manifests/vserver/instance.pp index 90b0b0a..dba9abb 100644 --- a/manifests/vserver/instance.pp +++ b/manifests/vserver/instance.pp @@ -52,7 +52,7 @@ define nodo::vserver::instance($context, $ensure = 'running', $proxy = false, } # Create a munin virtual resource to be realized in the node - @@munin_node { "$name": + @@munin_node { "${name}": port => $munin_port ? { false => "49$id", default => $munin_port, |