Make milanollo do more rsync
authorPeter Palfrader <peter@palfrader.org>
Mon, 24 Jun 2013 19:05:02 +0000 (21:05 +0200)
committerPeter Palfrader <peter@palfrader.org>
Mon, 24 Jun 2013 19:05:02 +0000 (21:05 +0200)
modules/debian-org/misc/local.yaml
modules/ferm/manifests/per-host.pp
modules/roles/files/syncproxy/rsyncd.conf [new file with mode: 0644]
modules/roles/manifests/init.pp
modules/roles/manifests/syncproxy.pp [new file with mode: 0644]

index fd3a359..4844fe7 100644 (file)
@@ -179,6 +179,8 @@ services:
     - reger.debian.org
   security_master:
     - chopin.debian.org
+  syncproxy:
+    - milanollo.debian.org
   www_master:
     - wolkenstein.debian.org
   keyring:
index 6985de7..72bf4f3 100644 (file)
@@ -3,7 +3,7 @@ class ferm::per-host {
                include ferm::zivit
        }
 
-       if $::hostname in [glinka,klecker,merikanto,milanollo,ravel,rietz,senfl,sibelius,stabile] {
+       if $::hostname in [glinka,klecker,merikanto,ravel,rietz,senfl,sibelius,stabile] {
                ferm::rule { 'dsa-rsync':
                        domain      => '(ip ip6)',
                        description => 'Allow rsync access',
diff --git a/modules/roles/files/syncproxy/rsyncd.conf b/modules/roles/files/syncproxy/rsyncd.conf
new file mode 100644 (file)
index 0000000..47403a2
--- /dev/null
@@ -0,0 +1,17 @@
+uid = nobody
+gid = nogroup
+max connections = 30
+syslog facility = daemon
+socket options = SO_KEEPALIVE
+timeout = 7200
+
+# weasel 2007-11-19
+log file =  /var/log/rsyncd/rsyncd.log
+
+[debian]
+  path = /srv/mirrors/debian/
+  comment = Full Debian FTP Archive (~660 GB; contact mirrors@debian.org for access)
+  auth users = *
+  read only = true
+  secrets file = /etc/rsyncd/debian.secrets
+
index d76823d..4dcdb38 100644 (file)
@@ -62,6 +62,10 @@ class roles {
                include roles::wiki
        }
 
+       if getfromhash($site::nodeinfo, 'syncproxy') {
+               include roles::syncproxy
+       }
+
        if getfromhash($site::nodeinfo, 'static_master') {
                include roles::static_master
        }
diff --git a/modules/roles/manifests/syncproxy.pp b/modules/roles/manifests/syncproxy.pp
new file mode 100644 (file)
index 0000000..080196f
--- /dev/null
@@ -0,0 +1,15 @@
+class roles::syncproxy {
+       rsync::site { 'syncproxy':
+               source => 'puppet:///modules/roles/syncproxy/rsyncd.conf',
+       }
+
+       file { '/etc/rsyncd':
+               ensure => 'directory'
+       }
+
+       file { '/etc/rsyncd/debian.secrets':
+               owner => 'root',
+               group => 'mirroradm',
+               mode => 0664,
+       }
+}