Try to configure ntpdate for hosts with broken RTC
[mirror/dsa-puppet.git] / modules / ntpdate / manifests / init.pp
diff --git a/modules/ntpdate/manifests/init.pp b/modules/ntpdate/manifests/init.pp
new file mode 100644 (file)
index 0000000..006daa5
--- /dev/null
@@ -0,0 +1,21 @@
+class ntpdate {
+    case getfromhash($nodeinfo, 'broken-rtc') {
+        true: {
+            package {
+                ntpdate: ensure => installed;
+                lockfile-progs: ensure => installed;
+            }
+            file {
+                "/etc/default/ntpdate":
+                    owner   => root,
+                    group   => root,
+                    mode    => 444,
+                    source  => [ "puppet:///modules/ntpdate/etc-default-ntpdate" ],
+                    ;
+            }
+        }
+    }
+}
+# vim:set et:
+# vim:set sts=4 ts=4:
+# vim:set shiftwidth=4: