From ab1896ad3e9f685ae96b09410936df63f8642dfa Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Wed, 23 May 2018 08:57:32 -0300 Subject: Manage users folder and ensure latest borgbackup package --- manifests/init.pp | 9 ++++++++- manifests/params.pp | 1 + 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/manifests/init.pp b/manifests/init.pp index a4492ca..f4ce07c 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -46,7 +46,7 @@ class backup( } package { "duplicity": ensure => installed, } - package { "borgbackup": ensure => installed, } + package { "borgbackup": ensure => latest, } package { "debconf-utils": ensure => installed, } # See http://www.rfc3092.net/2013/09/missing-modules-for-paramiko-and-gio-in-duplicity-foo/ @@ -64,6 +64,13 @@ class backup( mode => '0755', } + file { "${backup::params::backupdir_users}": + ensure => directory, + owner => root, + group => root, + mode => '0755', + } + file { "/var/log/backup": ensure => directory, owner => root, diff --git a/manifests/params.pp b/manifests/params.pp index e94e1d3..81b6fd4 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -2,6 +2,7 @@ class backup::params { # backup folder $backupdir = "/var/backups" $backupdir_remote = "$backupdir/remote" + $backupdir_users = "$backupdir/users" $backupdir_ensure = hiera('backup::dir::ensure', 'directory') # for data that's going to be encrypted and signed -- cgit v1.2.3