]> gitweb.fluxo.info Git - puppet-nodo.git/commitdiff
Updating ntp declarations
authorSilvio Rhatto <rhatto@riseup.net>
Fri, 25 Jan 2013 00:39:55 +0000 (22:39 -0200)
committerSilvio Rhatto <rhatto@riseup.net>
Fri, 25 Jan 2013 00:39:55 +0000 (22:39 -0200)
manifests/host.pp
manifests/nodo.pp
manifests/plug.pp
manifests/vserver.pp

index 42e739d3216edb82efb90daa5dce9349db6876a0..88e900542b68ae9ca513ecf7d6fd740c91c7b808 100644 (file)
@@ -27,9 +27,10 @@ class nodo::host inherits nodo {
   }
 
   # Time configuration
+  $ntpdate = hiera('nodo::host::ntpdate', True)
   case $ntpdate {
-    false:   { include timezone }
-    default: { include ntpdate  }
+    false:   { class { 'timezone': } }
+    default: { class { 'ntpdate':  } }
   }
 
   backupninja::sys { "sys":
index 67d8f7ca99ee5bf08ee62f388fd9f66be5b5eefb..edce74cfb9aa4bc8e2eb39cc69750df82b22b0d5 100644 (file)
@@ -44,15 +44,6 @@ class nodo {
   # Does not work well inside vservers
   class { 'runit': ensure => absent }
 
-  # Set timezone and ntp config
-  #
-  # We config those here but leave class inclusion elsewhere
-  # as ntp config differ from server to vserver.
-  #
-  $ntp_timezone = "Brazil/East"
-  $ntp_pool     = "south-america.pool.ntp.org"
-  $ntp_servers  = [ 'a.ntp.br', 'b.ntp.br', 'c.ntp.br' ]
-
   # Email delivery configuration
   case hiera('nodo::mail_delivery', 'exim') {
     'tunnel': {              
index f5992fce7bff7e2ee8d4d50bc911d26c665ebd27..08bb4c9a3122386652b3a9016bc7c34d2a09d234 100644 (file)
@@ -1,5 +1,4 @@
 class nodo::plug inherits nodo {
-  include ntpdate
   include syslog-ng
   include utils::plug
   include sysctl
@@ -7,7 +6,7 @@ class nodo::plug inherits nodo {
 
   monkeysphere_host { "${::hostname}": }
 
-  class { 'firewall': }
+  class { [ 'ntpdate', 'firewall' ]:  }
 
   backupninja::sys { "sys":
     ensure     => present,
index a889e9ae762150364113ee404a2d6d1b972e92c7..6854aba69fd5e86d99d942d147259cc76f023af3 100644 (file)
@@ -1,6 +1,5 @@
 class nodo::vserver inherits nodo {
-  include timezone
-
+  class { 'timezone': }
   class { 'syslog-ng::vserver': }
 
   backupninja::sys { "sys":