case $hostname {
geo1,geo2,geo3:
- { include geodns }
- default: {}
+ {
+ include geodns
+ include ntp::server
+ }
+ default: {
+ }
}
case $brokenhosts {
"true": { include hosts }
"pdksh": ensure => installed;
"ksh": ensure => installed;
"csh": ensure => installed;
- "ntp": ensure => installed;
"locales-all": ensure => installed;
"libpam-pwdfile": ensure => installed;
"vim": ensure => installed;
--- /dev/null
+##
+## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
+## USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
+##
+
+driftfile /var/lib/ntp/ntp.drift
+statsdir /var/log/ntpstats/
+
+statistics loopstats peerstats clockstats
+filegen loopstats file loopstats type day enable
+filegen peerstats file peerstats type day enable
+filegen clockstats file clockstats type day enable
+server geo1.debian.org iburst dynamic
+server geo2.debian.org iburst dynamic
+server geo3.debian.org iburst dynamic
+
+restrict -4 default kod notrap nomodify nopeer noquery
+restrict -6 default kod notrap nomodify nopeer noquery
+
+restrict 127.0.0.1
+restrict ::1
--- /dev/null
+##
+## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
+## USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
+##
+
+driftfile /var/lib/ntp/ntp.drift
+statsdir /var/log/ntpstats/
+
+statistics loopstats peerstats clockstats
+filegen loopstats file loopstats type day enable
+filegen peerstats file peerstats type day enable
+filegen clockstats file clockstats type day enable
+server 0.debian.pool.ntp.org iburst dynamic
+server 1.debian.pool.ntp.org iburst dynamic
+server 2.debian.pool.ntp.org iburst dynamic
+server 3.debian.pool.ntp.org iburst dynamic
+
+restrict -4 default kod notrap nomodify nopeer noquery
+restrict -6 default kod notrap nomodify nopeer noquery
+
+restrict 127.0.0.1
+restrict ::1
--- /dev/null
+class ntp::client inherits ntp {
+ file { "/etc/ntp.conf":
+ owner => root,
+ group => root,
+ mode => 440,
+ source => [ "puppet:///ntp/client.conf" ],
+ notify => Exec["ntp restart"],
+ require => Package["ntp"]
+ ;
+ }
+}
--- /dev/null
+class ntp {
+ package { ntp: ensure => installed }
+ file { "/var/lib/ntp/":
+ ensure => directory,
+ owner => ntp,
+ group => ntp,
+ mode => 755
+ ;
+ }
+ exec { "ntp restart":
+ path => "/etc/init.d:/usr/bin:/usr/sbin:/bin:/sbin",
+ refreshonly => true,
+ }
+}
--- /dev/null
+class ntp::server inherits ntp {
+ file { "/etc/ntp.conf":
+ owner => root,
+ group => root,
+ mode => 440,
+ source => [ "puppet:///ntp/server.conf" ],
+ notify => Exec["ntp restart"],
+ require => Package["ntp"]
+ ;
+ "/var/lib/ntpstats":
+ ensure => directory,
+ owner => ntp,
+ group => ntp,
+ mode => 755
+ ;
+ }
+}