summaryrefslogtreecommitdiffstats
path: root/tozt/tarsnap/manifests/init.pp
blob: c397164dc250bf0f5cf9456ca98de6dc4bd5ba07 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
class tarsnap {
  include cron

  package { 'tarsnap':
    ensure => installed;
  }

  package::makepkg { 'acts':
    ensure => installed,
    require => Package['tarsnap'];
  }

  file {
    '/etc/tarsnap/tarsnap.conf':
      source => 'puppet:///modules/tarsnap/tarsnap.conf';
    '/etc/acts.conf':
      source => 'puppet:///modules/tarsnap/acts.conf';
    '/etc/cron.daily/acts':
      source => 'puppet:///modules/tarsnap/acts',
      mode => '0755',
      require => [
        File['/etc/acts.conf'],
        Package::Makepkg['acts'],
        Class['cron'],
      ];
  }

  secret { "/etc/tarsnap/machine-key":
    source => 'tarsnap',
  }
}