]> git.donarmstrong.com Git - dsa-puppet.git/blobdiff - modules/debian-org/manifests/init.pp
Make rc.local a template, make swap on zani
[dsa-puppet.git] / modules / debian-org / manifests / init.pp
index e009031a1df9a24e251d659b47796278b4cb28e3..dc9d2722f1e802cc3c68e74bc3e95a52dea19b66 100644 (file)
@@ -6,7 +6,7 @@ class debian-org {
        if getfromhash($site::nodeinfo, 'hoster', 'mirror-debian') {
                $mirror = getfromhash($site::nodeinfo, 'hoster', 'mirror-debian')
        } else {
-               $mirror = 'http://http.debian.net/debian/'
+               $mirror = 'http://ftp.debian.org/debian/'
        }
        if $::lsbmajdistrelease < 7 {
                $mirror_backports = 'http://backports.debian.org/debian-backports/'
@@ -14,6 +14,13 @@ class debian-org {
                $mirror_backports = $mirror
        }
 
+       if $systemd {
+               include systemd
+               $servicefiles = 'present'
+       } else {
+               $servicefiles = 'absent'
+       }
+
        $debianadmin = [
                'debian-archive-debian-samhain-reports@master.debian.org',
                'debian-admin@ftbfs.de',
@@ -244,7 +251,19 @@ class debian-org {
                ensure  => directory,
                mode => 0755,
        }
-        file { '/etc/systemd/system/puppet.service':
+       file { '/etc/systemd/system/ud-replicated.service':
+               ensure => $servicefiles,
+               source => 'puppet:///modules/debian-org/ud-replicated.service',
+               notify => Exec['systemctl daemon-reload'],
+       }
+       if $systemd {
+               file { '/etc/systemd/system/multi-user.target.wants/ud-replicated.service':
+                       ensure => 'link',
+                       target => '../ud-replicated.service',
+                       notify => Exec['systemctl daemon-reload'],
+               }
+       }
+       file { '/etc/systemd/system/puppet.service':
                ensure => 'link',
                target => '/dev/null',
                notify => Exec['systemctl daemon-reload'],
@@ -268,7 +287,7 @@ class debian-org {
        }
        file { '/etc/rc.local':
                mode   => '0755',
-               source => 'puppet:///modules/debian-org/rc.local',
+               content => template('debian-org/rc.local.erb'),
                notify => Exec['service rc.local start'],
        }
        file { '/etc/dsa':