aboutsummaryrefslogtreecommitdiff
path: root/manifests/rdiff.pp
blob: cbb1f096f3dce982f49b604aae27f0663dd0155a (plain)
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
32
33
# default backupninja::rdiff configuration
define backup::rdiff(
  $port = '22',
  $ensure = present
) {
  backupninja::rdiff { "rdiff-$title.$domain":
    ensure         => $ensure,
    options        => "--remote-schema 'ssh -p $port -C %s rdiff-backup --server'",
    # [source]
    keep           => "10",
    include        => $backup::params::include_encrypted,
    exclude        => $backup::params::exclude_encrypted,
    # [dest]
    type           => "remote",
    host           => "$title.$domain",
    home           => "${backup::params::backupdir}/remote/$fqdn",
    subfolder      => "rdiff",
    user           => "$hostname",
    sshoptions     => "-p $port",
    backupkeytype  => "rsa",
    backupkeystore => "puppet:///pubkeys",
    sandbox        => false,
  }

  # Currently we're not managing ssh keys this way
  #if !defined(Ssh_local_key["$hostname"]) {
  #  ssh_local_key { "$hostname":
  #    owner => root,
  #    group => root,
  #    home  => '/root',
  #  }
  #}
}